@@ -177,83 +177,83 @@ func getRedactors(path string) ([]Redactor, error) {
177177 // ipv4
178178 {
179179 regex : `(?P<mask>\b(?P<drop>25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?P<drop>25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?P<drop>25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?P<drop>25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\b)` ,
180- name : "default ipv4 redactor " ,
180+ name : "Redact ipv4 addresses " ,
181181 },
182182 // TODO: ipv6
183183 // aws secrets
184184 {
185185 regex : `(?i)(\\\"name\\\":\\\"[^\"]*SECRET_?ACCESS_?KEY\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
186- name : "default SECRET_ACCESS_KEY redactor " ,
186+ name : "Redact AWS Secret Access Key values in JSON " ,
187187 },
188188 {
189189 regex : `(?i)(\\\"name\\\":\\\"[^\"]*ACCESS_?KEY_?ID\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
190- name : "default ACCESS_KEY_ID redactor " ,
190+ name : "Redact AWS Access Key ID values in JSON " ,
191191 },
192192 {
193193 regex : `(?i)(\\\"name\\\":\\\"[^\"]*OWNER_?ACCOUNT\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
194- name : "default OWNER_ACCOUNT redactor " ,
194+ name : "Redact AWS Owner and Account Numbers in JSON " ,
195195 },
196196 // passwords in general
197197 {
198198 regex : `(?i)(\\\"name\\\":\\\"[^\"]*password[^\"]*\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
199- name : "default password redactor " ,
199+ name : "Redact password environment variables in JSON " ,
200200 },
201201 // tokens in general
202202 {
203203 regex : `(?i)(\\\"name\\\":\\\"[^\"]*token[^\"]*\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
204- name : "default token redactor " ,
204+ name : "Redact values that look like API tokens in JSON " ,
205205 },
206206 {
207207 regex : `(?i)(\\\"name\\\":\\\"[^\"]*database[^\"]*\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
208- name : "default database redactor " ,
208+ name : "Redact database connection strings in JSON " ,
209209 },
210210 {
211211 regex : `(?i)(\\\"name\\\":\\\"[^\"]*user[^\"]*\\\",\\\"value\\\":\\\")(?P<mask>[^\"]*)(\\\")` ,
212- name : "default user redactor " ,
212+ name : "Redact usernames in JSON " ,
213213 },
214214 // connection strings with username and password
215215 // http://user:password@host:8888
216216 {
217217 regex : `(?i)(https?|ftp)(:\/\/)(?P<mask>[^:\"\/]+){1}(:)(?P<mask>[^@\"\/]+){1}(?P<host>@[^:\/\s\"]+){1}(?P<port>:[\d]+)?` ,
218- name : "default connection string redactor " ,
218+ name : "Redact connection strings with username and password " ,
219219 },
220220 // user:password@tcp(host:3309)/db-name
221221 {
222222 regex : `\b(?P<mask>[^:\"\/]*){1}(:)(?P<mask>[^:\"\/]*){1}(@tcp\()(?P<mask>[^:\"\/]*){1}(?P<port>:[\d]*)?(\)\/)(?P<mask>[\w\d\S-_]+){1}\b` ,
223- name : "default db connection string redactor " ,
223+ name : "Redact database connection strings that contain username and password " ,
224224 },
225225 // standard postgres and mysql connection strings
226226 {
227227 regex : `(?i)(Data Source *= *)(?P<mask>[^\;]+)(;)` ,
228- name : "default Data Source redactor " ,
228+ name : "Redact database connection string ' Data Source' values " ,
229229 },
230230 {
231231 regex : `(?i)(location *= *)(?P<mask>[^\;]+)(;)` ,
232- name : "default location redactor " ,
232+ name : "Redact database connection string ' location' values " ,
233233 },
234234 {
235235 regex : `(?i)(User ID *= *)(?P<mask>[^\;]+)(;)` ,
236- name : "default User ID redactor " ,
236+ name : "Redact database connectin string ' User ID' values " ,
237237 },
238238 {
239239 regex : `(?i)(password *= *)(?P<mask>[^\;]+)(;)` ,
240- name : "default db- password redactor " ,
240+ name : "Redact database connection string ' password' values " ,
241241 },
242242 {
243243 regex : `(?i)(Server *= *)(?P<mask>[^\;]+)(;)` ,
244- name : "default server redactor " ,
244+ name : "Redact database connection string 'Server' values " ,
245245 },
246246 {
247247 regex : `(?i)(Database *= *)(?P<mask>[^\;]+)(;)` ,
248- name : "default db- database redactor " ,
248+ name : "Redact database connection string 'Database' values " ,
249249 },
250250 {
251251 regex : `(?i)(Uid *= *)(?P<mask>[^\;]+)(;)` ,
252- name : "default Uid redactor " ,
252+ name : "Redact database connection string 'UID' values " ,
253253 },
254254 {
255255 regex : `(?i)(Pwd *= *)(?P<mask>[^\;]+)(;)` ,
256- name : "default Pwd redactor " ,
256+ name : "Redact database connection string 'PWD' values " ,
257257 },
258258 }
259259
@@ -274,37 +274,37 @@ func getRedactors(path string) ([]Redactor, error) {
274274 {
275275 line1 : `(?i)"name": *"[^\"]*SECRET_?ACCESS_?KEY[^\"]*"` ,
276276 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
277- name : "default multiline SECRET_ACCESS_KEY redactor " ,
277+ name : "Redact AWS Secret Access Key values in multiline JSON " ,
278278 },
279279 {
280280 line1 : `(?i)"name": *"[^\"]*ACCESS_?KEY_?ID[^\"]*"` ,
281281 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
282- name : "default multiline ACCESS_KEY_ID redactor " ,
282+ name : "Redact AWS Access Key ID values in multiline JSON " ,
283283 },
284284 {
285285 line1 : `(?i)"name": *"[^\"]*OWNER_?ACCOUNT[^\"]*"` ,
286286 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
287- name : "default multiline OWNER_ACCOUNT redactor " ,
287+ name : "Redact AWS Owner and Account Numbers in multiline JSON " ,
288288 },
289289 {
290290 line1 : `(?i)"name": *".*password[^\"]*"` ,
291291 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
292- name : "default multiline password redactor " ,
292+ name : "Redact password environment variables in multiline JSON " ,
293293 },
294294 {
295295 line1 : `(?i)"name": *".*token[^\"]*"` ,
296296 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
297- name : "default multiline token redactor " ,
297+ name : "Redact values that look like API tokens in multiline JSON " ,
298298 },
299299 {
300300 line1 : `(?i)"name": *".*database[^\"]*"` ,
301301 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
302- name : "default multiline database redactor " ,
302+ name : "Redact database connection strings in multiline JSON " ,
303303 },
304304 {
305305 line1 : `(?i)"name": *".*user[^\"]*"` ,
306306 line2 : `(?i)("value": *")(?P<mask>.*[^\"]*)(")` ,
307- name : "default multiline user redactor " ,
307+ name : "Redact usernames in multiline JSON " ,
308308 },
309309 }
310310
0 commit comments