[Opendnssec-user] would some kind soul share a clue?

Jack Craig jack.craig.aptos at gmail.com
Thu Dec 19 23:45:28 UTC 2013


My Env is Ubuntu 12.04, softHSMv2, xsectool1.2.0.

I am trying to sign a file using SHMv2 & xsectool.

i run a cmd like, ...

xmlsectool-1.2.0/xmlsectool.sh --verbose --sign --digest SHA256
--digestAlgorithm http://www.w3.org/2000/09/xmldsig#sha1--signatureAlgorithm
http://www.w3.org/2000/09/xmldsig#dsa-sha1 --pkcs11Config
/home/jackc/src/xmlsectool-1.2.0/pksc11.cfg --key 0 --keyPassword 2222
--keystoreProvider sun.security.pkcs11.SunPKCS11 --inFile
/home/jackc/src/xmlsectool-1.2.0/sample.xml --outFile
/home/jackc/src/xmlsectool-1.2.0/newout.xml


softhsm-util --show-slot
Available slots:
Slot 0
    Slot info:
        Description:      SoftHSM slot
0
        Manufacturer ID:  SoftHSM project
        Hardware version: 2.0
        Firmware version: 2.0
        Token present:    yes
    Token info:
        Manufacturer ID:  SoftHSM project
        Model:            SoftHSM v2
        Hardware version: 2.0
        Firmware version: 2.0
        Serial number:    aecde8d999bf4a6a
        Initialized:      yes
        User PIN init.:   yes
        Label:            tok0
Slot 1
    Slot info:
        Description:      SoftHSM slot
1
        Manufacturer ID:  SoftHSM project
        Hardware version: 2.0
        Firmware version: 2.0
        Token present:    yes
    Token info:
        Manufacturer ID:  SoftHSM project
        Model:            SoftHSM v2
        Hardware version: 2.0
        Firmware version: 2.0
        Serial number:    e4d1db72d6354345
        Initialized:      yes
        User PIN init.:   yes
        Label:


and get back, ...
ome/jackc/src/xmlsectool-1.2.0/xmlsectool.sh
--verbose --sign --pkcs11Config /home/jackc/src/xmlsectool-1.2.0/pksc11.cfg
--key 0 --keyPassword 2222 --keystoreProvider sun.security.pkcs11.SunPKCS11
--inFile sample.xml --outFile newout.xml

INFO  XmlSecTool - Reading XML document from file 'sample.xml'
DEBUG XmlSecTool - Building DOM parser
DEBUG XmlSecTool - Parsing XML input stream
INFO  XmlSecTool - XML document parsed and is well-formed.
DEBUG XmlSecTool - Preparing to sign document
DEBUG CredentialHelper - Install PKCS11 provider
DEBUG CredentialHelper - Creating PKCS11 keystore with provider
sun.security.pkcs11.SunPKCS11 and configuration file
/home/jackc/src/xmlsectool-1.2.0/pksc11.cfg
DEBUG CredentialHelper - Initializing PKCS11 keystore
DEBUG CredentialHelper - Successfully read credentials from keystore
ERROR XmlSecTool - Unknown error
java.lang.NullPointerException: null
    at
edu.internet2.middleware.security.XmlSecTool.sign(XmlSecTool.java:433)
~[xmlsectool-1.2.0.jar:na]
    at
edu.internet2.middleware.security.XmlSecTool.main(XmlSecTool.java:188)
~[xmlsectool-1.2.0.jar:na]


suggestions? TIA, jackc...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opendnssec.org/pipermail/opendnssec-user/attachments/20131219/0859e9f4/attachment.htm>


More information about the Opendnssec-user mailing list