old Mac linker is picky about argument order - static libs last
[LibreOffice.git] / libxmlsec / README
blob2484bf2300e464ada3eb21db5600da92ca32b0fd
1 XML signing, etc. From [http://www.aleksey.com/xmlsec/]. Heavily patched.
3 The XML Security library has been modified, so that there is NO verification of
4 the certificate during sign or verification operation. On Windows this was done
5 in the function xmlSecMSCryptoX509StoreVerify (file src/mscrypto/x509vfy.c) and
6 on UNIX in xmlSecNssX509StoreVerify (file src/nss/x509vfy.c).
8 The implementation creates certificates from all of the X509Data children, such
9 as X509IssuerSerial and X509Certificate and stores them in a certificate store
10 (see xmlsec/src/mscrypto/x509.c:xmlSecMSCryptoX509DataNodeRead). It must then
11 find the certificate containing the public key which is used for validation
12 within that store. This is done in xmlSecMSCryptoX509StoreVerify. This function
13 however only takes those certificates into account which can be validated. This
14 was changed by the patch xmlsec1-noverify.patch, which prevents this certificate
15 validation.
17 xmlSecMSCryptoX509StoreVerify iterates over all certificates contained or
18 referenced in the X509Data elements and selects one which is no issuer of any of
19 the other certificates. This certificate is not necessarily the one which was
20 used for signing but it must contain the proper validation key, which is
21 sufficient to validate the signature. See 
22 http://www.w3.org/TR/xmldsig-core/#sec-X509Data 
23 for details.
25 There is a flag XMLSEC_KEYINFO_FLAGS_X509DATA_DONT_VERIFY_CERTS that can be set
26 in a xmlSecKeyInfoCtx (see function xmlSecNssKeyDataX509XmlRead, in file
27 src/nss/x509.c), which indicates that one can turn off the validation. However,
28 setting it will cause that the validation key is not found. If the flag is set,
29 then the key is not extracted from the certificate store which contains all the
30 certificates of the X509Data elements. In other words, the certificates which
31 are delivered within the XML signature are not used when looking for suitable
32 validation key.