File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed
python/ql/src/semmle/python Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -545,7 +545,7 @@ module Cryptography {
545545 /** Gets the name of the cryptographic algorithm (for example `"RSA"` or `"AES"`). */
546546 string getName ( ) { result = range .getName ( ) }
547547
548- /** Gets the argument that specifies size of the key in bits, if available. */
548+ /** Gets the argument that specifies the size of the key in bits, if available. */
549549 DataFlow:: Node getKeySizeArg ( ) { result = range .getKeySizeArg ( ) }
550550
551551 /**
@@ -600,7 +600,7 @@ module Cryptography {
600600 /** Gets the name of the cryptographic algorithm (for example `"RSA"`). */
601601 abstract string getName ( ) ;
602602
603- /** Gets the argument that specifies size of the key in bits, if available. */
603+ /** Gets the argument that specifies the size of the key in bits, if available. */
604604 abstract DataFlow:: Node getKeySizeArg ( ) ;
605605
606606 /**
Original file line number Diff line number Diff line change @@ -77,12 +77,12 @@ private module CryptodomeModel {
7777 }
7878
7979 /** Gets the argument that specifies the curve to use (a string). */
80- DataFlow:: Node getCurveArg ( ) { result in [ this .getArgByName ( "curve" ) ] }
80+ DataFlow:: Node getCurveArg ( ) { result = this .getArgByName ( "curve" ) }
8181
8282 /** Gets the name of the curve to use, as well as the origin that explains how we obtained this name. */
8383 string getCurveWithOrigin ( DataFlow:: Node origin ) {
8484 exists ( StrConst str | origin = DataFlow:: exprNode ( str ) |
85- origin . ( DataFlow :: LocalSourceNode ) . flowsTo ( this .getCurveArg ( ) ) and
85+ origin = this .getCurveArg ( ) . getALocalSource ( ) and
8686 result = str .getText ( )
8787 )
8888 }
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ private module CryptographyModel {
3535 |
3636 // obtained by manually looking at source code in
3737 // https://github.com/pyca/cryptography/blob/cba69f1922803f4f29a3fde01741890d88b8e217/src/cryptography/hazmat/primitives/asymmetric/ec.py#L208-L300
38- curveName = "SECT571R1" and keySize = 570
38+ curveName = "SECT571R1" and keySize = 570 // Indeed the numbers do not match.
3939 or
4040 curveName = "SECT409R1" and keySize = 409
4141 or
You can’t perform that action at this time.
0 commit comments