aboutsummaryrefslogtreecommitdiff
path: root/asn1crypto
AgeCommit message (Collapse)Author
2021-02-12[LSC] Add LOCAL_LICENSE_KINDS to external/python/asn1cryptoandroid-s-preview-1Bob Badour
Added SPDX-license-identifier-MIT to: Android.bp asn1crypto/Android.bp Bug: 68860345 Bug: 151177513 Bug: 151953481 Test: m all Exempt-From-Owner-Approval: janitorial work Change-Id: Ie246bed6727ab34428a782b6d8bc08825d965150
2020-10-28Upgrade python/asn1crypto to 1.4.0Haibo Huang
Test: make Change-Id: I91c1d9e084d4804e09aa5d686816dba41512357e
2020-07-28Version 1.4.0wbond
2020-07-25Ensure keys.PublicKeyInfo.bit_size returns an intwbond
2020-07-25Tweak error messages on invalid OIDswbond
2020-07-25Merge pull request #174 from joernheissler/oid-arc-2Will Bond
Fix parsing of ObjectIdentifier's first octet.
2020-05-04Fix a syntax typoMiro Hrončok
This worked for now, but is SyntaxError in Python 3.9.0a6: File "/usr/lib/python3.9/site-packages/asn1crypto/x509.py", line 1139 return', '.join( ^ SyntaxError: invalid string prefix (The Python change might actually be reverted before 3.9 final, but this can be fixed anyway.)
2020-01-05Fix parsing of ObjectIdentifier's first octet.Jörn Heissler
X.660 §7.6 specifies that the first arc of an OID must be 0 to 2 and the second arc below arcs 0 and 1 must be 0 to 39. Arc 2 is not restricted in that way. The algorithm for parsing ObjectIdentifiers did not work for OID 2.X with X >= 40. This change also enforces above restrictions when setting an ObjectIdentifier.
2020-01-04Upgrade python/asn1crypto to 1.3.0android-r-preview-1Haibo Huang
Test: None Change-Id: I27182f97cedcedcd74d014428a888fb7bb1e3f0d
2020-01-04Version 1.3.0wbond
2019-12-25Merge pull request #171 from commonism/encrypt_key_prefWill Bond
add support for id-aa-encrypKeyPref in pkcs7/cms mail signatures
2019-11-20lintMarkus Kötter
2019-11-20lintMarkus Kötter
2019-11-20id-aa-encrypKeyPref - as defined in RFC2633Markus Kötter
2019-11-19fix fq import namesMarkus Kötter
2019-11-19add support for id-aa-encrypKeyPref in pkcs7/cms mail signaturesMarkus Kötter
- oid 1.2.840.113549.1.9.16.2.11
2019-11-11Add __getinitargs__ method to util.timezoneJörn Heissler
If a timezone object is copied, its __reduce__ method is called which in turn calls __getinitargs__ to get arguments for __init__ on the new object. If that function is missing, __init_ is called with too few parameters. Problem can be triggered by calling copy or untag on UTCTime or GeneralizedTime or any other object where the native value includes a datetime Fixes #167
2019-11-05Merge pull request #166 from joernheissler/i163Will Bond
Add brainpool curves from rfc5639
2019-11-05Merge pull request #165 from joernheissler/fix_key_sizesWill Bond
Fixed some incorrectly computed EC private key sizes.
2019-11-04Fixed some incorrectly computed EC private key sizes.Jörn Heissler
Private key is an integer from interval [1, curve_order). The curve order is denoted by n in SECG or q in some RFCs. The byte length is therefore ceil(log2(n) / 8). Double checked by comparing to what openssl generates.
2019-11-04Fix x509.Certificate.subject_directory_attributes_value propertyJörn Heissler
Closes: #159
2019-11-04Add brainpool curves from rfc5639Jörn Heissler
Closes: #163
2019-10-16Version 1.2.0wbond
2019-10-16Remove comments in load_order() showing dependencieswbond
The comments resulted in making it hard to copy-paste and messy looking.
2019-10-14Add asn1crypto.load_order()wbond
2019-10-12Version 1.1.0wbond
2019-10-12Add more (legacy) OIDs to keys.NamedCurve()wbond
2019-10-08Add UID attribute from RFC4519spchan
2019-10-04Version 1.0.1wbond
2019-10-04Fix an absolute import that should have been relativewbond
2019-10-02Upgrade python/asn1crypto to 1.0.0ndk-sysroot-r21Haibo Huang
Test: None Change-Id: Id976fdd7c170f3111e35c4a2cde69aba8715c243
2019-10-02Version 1.0.0wbond
2019-10-01Preserve the ability to pass core.Null() into ocsp.CertStatus()wbond
2019-10-01Added ocsp.StatusGood() and ocsp.StatusUnknown() for ocsp.CerStatus().nativewbond
2019-10-01Allow X.509 certificates with improperly encoded DNSName and EmailAddresswbond
2019-10-01Prevent UnboundLocalError on empty asn1crypto.x509.IPAddress()wbond
2019-10-01Handle BER-encoded indefinite length values betterwbond
- Ensure when we have trailing EOC bytes to include them when dumping - If we know the encoding is indefinite length, re-encode using DER
2019-09-28Add trailer info to .debug() outputwbond
2019-09-28When copying a BER-encoded indefinite-length value, force it to be DER-encodedwbond
2019-09-27Restrict core.IntegerBitString() and core.IntegerOctetString() to positive ↵wbond
integers
2019-09-27Merge pull request #148 from joernheissler/bit_string_parsingWill Bond
Refactor BitString parsing
2019-09-23Fix encoding of tag values over 30wbond
2019-09-23Fix passing class_ to core.Asn1Value(), add support for passing methodwbond
2019-09-21Add unused_bits property to BitString classesJörn Heissler
Encoded Bit Strings can have 0-7 unused bits in the rightmost byte. With DER encoding, those bits must be zero. But some encoders might put in other values. Sometimes this feature is abused (CVE-2014-8275). The added property allows to read those bits for debugging or for detecting such tampering.
2019-09-21Refactor BitString parsingJörn Heissler
Closes: #147
2019-09-21Merge pull request #138 from space88man/rsassa_pssWill Bond
keys.py: add RSASSA_PSS OIDs from RFC4055
2019-09-13Create asn1crypto_tests package, along with supporting toolingwbond
Adds the following tasks: - python run.py build - python run.py version {pep440_version} Tests may now be executed a number of different ways and will automatically ensure the local copy of asn1crypto is used, if run from a Git working copy, or archive of a working copy. Versioning scheme switched from SemVer to PEP 440 since that is what the Python ecosystem tooling supports.
2019-09-10Ensure keys.NamedCurve.register() works if setup() has been run or notwbond
2019-08-21Fix ValueError in keys.NamedCurve.register()wbond
If any NamedCurve object was created before calling register(), the _reverse_map would not be properly set for the custom value.
2019-08-21Ensure EC private keys are encoded to the correct width, per RFC 5915wbond