diff options
author | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2014-11-14 20:46:24 +0100 |
---|---|---|
committer | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2014-11-14 20:48:19 +0100 |
commit | b27f1ad7dbfd248d98bc54ab5969ea4429c6b92d (patch) | |
tree | b3a2a864c987805edfb408f6864af9a874679503 /tests/pkix.asn | |
parent | c73ef9293c2c13b40e4fad78ae367c77272a5395 (diff) | |
download | libtasn1-b27f1ad7dbfd248d98bc54ab5969ea4429c6b92d.tar.gz |
Added test for ResponseData decoding-encoding issue
Diffstat (limited to 'tests/pkix.asn')
-rw-r--r-- | tests/pkix.asn | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/tests/pkix.asn b/tests/pkix.asn index 579dd57..7ce8abe 100644 --- a/tests/pkix.asn +++ b/tests/pkix.asn @@ -1238,6 +1238,51 @@ id-on-xmppAddr OBJECT IDENTIFIER ::= { id-on 5 } XmppAddr ::= UTF8String +-- ocsp + +BasicOCSPResponse ::= SEQUENCE { + tbsResponseData ResponseData, + signatureAlgorithm AlgorithmIdentifier, + signature BIT STRING, + certs [0] EXPLICIT SEQUENCE OF Certificate OPTIONAL } + +ResponseData ::= SEQUENCE { + version [0] EXPLICIT INTEGER DEFAULT 0, + responderID ResponderID, + producedAt GeneralizedTime, + responses SEQUENCE OF SingleResponse, + responseExtensions [1] EXPLICIT Extensions OPTIONAL } + +ResponderID ::= CHOICE { +-- Changed to work with the libtasn1 parser. + byName [1] EXPLICIT RDNSequence, --Name + byKey [2] OCTET STRING --SHA-1 hash of responder's public key +} + +CertID ::= SEQUENCE { + hashAlgorithm AlgorithmIdentifier, + issuerNameHash OCTET STRING, -- Hash of Issuer's DN + issuerKeyHash OCTET STRING, -- Hash of Issuers public key + serialNumber CertificateSerialNumber } + +CertStatus ::= CHOICE { + good [0] IMPLICIT NULL, + revoked [1] IMPLICIT RevokedInfo, + unknown [2] IMPLICIT UnknownInfo } + +SingleResponse ::= SEQUENCE { + certID CertID, + certStatus CertStatus, + thisUpdate GeneralizedTime, + nextUpdate [0] EXPLICIT GeneralizedTime OPTIONAL, + singleExtensions [1] EXPLICIT Extensions OPTIONAL } + +RevokedInfo ::= SEQUENCE { + revocationTime GeneralizedTime, + revocationReason [0] EXPLICIT CRLReason OPTIONAL } + +UnknownInfo ::= NULL -- this can be replaced with an enumeration + END -- Copyright (C) 2002-2014 Free Software Foundation, Inc. @@ -1256,3 +1301,4 @@ END -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. + |