mirror of
https://github.com/sasjs/lint.git
synced 2026-01-10 05:50:05 +00:00
chore(*): add support for SASENC passwords
This commit is contained in:
@@ -5,7 +5,7 @@ const name = 'noEncodedPasswords'
|
||||
const description = 'Disallow encoded passwords in SAS code.'
|
||||
const warning = 'Line contains encoded password'
|
||||
const test = (value: string, lineNumber: number) => {
|
||||
const regex = new RegExp(/{sas\d{2,4}}[^;"'\s]*/, 'gi')
|
||||
const regex = new RegExp(/{sas(\d{2,4}|enc)}[^;"'\s]*/, 'gi')
|
||||
const matches = value.match(regex)
|
||||
if (!matches || !matches.length) return []
|
||||
return matches.map((match) => ({
|
||||
|
||||
Reference in New Issue
Block a user