The utility Sc14n performs the C14N transformation of a straightforward XML document.
The transformation can be of the complete document, a subset of the document, or the document excluding a given subset. The subset can be specified either by its ID or tag name.
>>> # Example 1. Excludes the first element with the tag name <Signature>
>>> r = C14n.file2file("c14nfile1.txt", "input.xml", "Signature", Tran.OMITBYTAG)
True
>>> # Example 2. Finds and transforms the first element with the tag name <SignedInfo>
>>> r = C14n.file2file("c14nfile2.txt", "input.xml", "SignedInfo", Tran.SUBSETBYTAG)
True
>>> # Example 3. Finds and transforms the third element with the tag name <Data>
>>> r = C14n.file2file("c14nfile3.txt", "input.xml", "Data[3]", Tran.SUBSETBYTAG)
True
>>> # Example 4. Finds and transforms the element with attribute Id="foo"
>>> r = C14n.file2file("c14nfile4.txt", "input.xml", "foo", Tran.SUBSETBYID)
True
>>> # Example 5. Finds and transforms the element with attribute ID="bar"
>>> r = C14n.file2file("c14nfile5.txt", "input.xml", "ID=bar", Tran.SUBSETBYID)
True
>>> # Example 6. Excludes element with attribute Id="thesig"
>>> r = C14n.file2file("c14nfile6.txt", "input.xml", "thesig", Tran.OMITBYID)
True
For full details of all available methods and options, please see the documentation.
Sc14n can be used with a cryptographic library to sign XML documents using XML-DSIG. We recommend our cryptographic library CryptoSys PKI available from https://cryptosys.net/pki/.
System requirements
Windows platforms with Python 3. Requires the Windows program Sc14n to be installed on your system, available from https://cryptosys.net/sc14n/.
To carry out the cryptographic signing examples in test_sc14n-pki.py you must also install CryptoSys PKI and cryptosyspki.py (see links below).
Downloads
Sc14n: https://cryptosys.net/sc14n/
CryptoSys PKI: https://cryptosys.net/pki/
cryptosyspki.py: https://pypi.python.org/pypi/cryptosyspki/
Contact
For more information or to make suggestions, please contact us at https://cryptosys.net/contact/
Metadata
Release files for sc14npy 2.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| sc14npy-2.1.1.zip | 47.5 kB | Without provenance | Details |
Release files / sc14npy-2.1.1.zip
| Download URL | sc14npy-2.1.1.zip |
|---|---|
| Size | 47.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
dbe035d77d5093b2cc9626e249191521953e64a652427907b82b828119b98682
|
|
BLAKE2b-256 checksum How to use checksums |
2bfd0a2d532e4f4bb1aab6645e3318c18e4e6ff8a03bc9979de31936fa8bebc2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.9.1 pkginfo/1.4.1 requests/2.18.3 setuptools/36.2.7 requests-toolbelt/0.8.0 tqdm/4.15.0 CPython/2.7.12
|
Security for sc14npy 2.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.