7618:cba5c14bcd5e | 7619:ef2b5af23ce7 |
---|---|
27 list of codes | 27 list of codes |
28 @rtype dict | 28 @rtype dict |
29 """ | 29 """ |
30 return { | 30 return { |
31 "Call": [ | 31 "Call": [ |
32 (checkHashlibNew, ("S324",)), | 32 (checkHashlibNew, ("S331",)), |
33 ], | 33 ], |
34 } | 34 } |
35 | 35 |
36 | 36 |
37 def checkHashlibNew(reportError, context, config): | 37 def checkHashlibNew(reportError, context, config): |
63 name.lower() in insecureHashes | 63 name.lower() in insecureHashes |
64 ): | 64 ): |
65 reportError( | 65 reportError( |
66 context.node.lineno - 1, | 66 context.node.lineno - 1, |
67 context.node.col_offset, | 67 context.node.col_offset, |
68 "S324", | 68 "S331", |
69 "M", | 69 "M", |
70 "H", | 70 "H", |
71 name.upper() | 71 name.upper() |
72 ) | 72 ) |