X-Git-Url: http://www.git.cypherpunks.ru/?a=blobdiff_plain;f=doc%2Fexamples.rst;h=953001a36c9c6b98c16f1ff512595c9533da043e;hb=a68abb6caad16e63cdb6cc22326bd1078215672e;hp=5dace604dc254fcc8d1c00205a195ba8b084d353;hpb=ac1628691fa68bcc61a0374b219ead802b94e17b;p=pyderasn.git diff --git a/doc/examples.rst b/doc/examples.rst index 5dace60..953001a 100644 --- a/doc/examples.rst +++ b/doc/examples.rst @@ -235,7 +235,7 @@ ___________________ If you have got dictionaries with ObjectIdentifiers, like example one from ``tests/test_crts.py``:: - some_oids = { + stroid2name = { "1.2.840.113549.1.1.1": "id-rsaEncryption", "1.2.840.113549.1.1.5": "id-sha1WithRSAEncryption", [...] @@ -245,7 +245,7 @@ from ``tests/test_crts.py``:: then you can pass it to pretty printer to see human readable OIDs:: - $ python -m pyderasn --oids tests.test_crts:some_oids path/to/file + $ python -m pyderasn --oids tests.test_crts:stroid2name path/to/file [...] 37 [1,1, 11] . . . . . . >: SET OF 39 [1,1, 9] . . . . . . . . >: SEQUENCE OF @@ -362,7 +362,7 @@ Let's create some simple self-signed X.509 certificate from the ground:: tbs["validity"] = validity spki = SubjectPublicKeyInfo() - spki_algo_id = sign_algo_id.copy() + spki_algo_id = copy(sign_algo_id) spki_algo_id["algorithm"] = ObjectIdentifier("1.2.840.113549.1.1.1") spki["algorithm"] = spki_algo_id spki["subjectPublicKey"] = BitString(hexdec("".join((