-
-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RSAKeyValue tag (Modulus and Exponent) #52
Comments
They should be. How are you calling |
They are missing in the result. this way:
|
The reason is that you're giving it a value for Try not passing |
Ok I'll try... will tell you what happen very soon. It is related to en electronic invoice requirement. Thanks a lot. |
Andrey, I called "sign()" without cert. Now there come "modulus" and "exponent". I still did not reach the fire-test anyway, but think I should pass the verify first.. |
According to the XSD of XML signatures of the SII (Chile's IRS), both elements should be on the signature, KeyValue and X509Data. |
@Gallaecio, to your original question, the XML Security spec does not say anything about the requirement for both elements to be present. On the other hand, having both elements be present results in an ambiguity and/or extra work for the validator, and makes it easier for vulnerabilities to arise - the public key used to sign the document is already encoded in the cert (which is in X509Data). So the verifier must either ignore KeyValue or make sure it matches what's in the cert. |
- XMLSigner.sign(): add always_add_key_value kwarg to include both X509Data and KeyValue for ill-defined signing applications - XMLVerifier.verify(): reject signatures that contain both X509Data and KeyValue by default; add ignore_ambiguous_key_info kwarg to bypass - Add security warnings in docs Fixes #52 Fixes #65 Fixes #64
Since these values are not provided in the sign() return value, which should be the best way to add them?
Thanks
The text was updated successfully, but these errors were encountered: