coolkey | How to build on various platforms
kandi X-RAY | coolkey Summary
kandi X-RAY | coolkey Summary
How to build on various platforms. A more up to date version of this may be found at
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of coolkey
coolkey Key Features
coolkey Examples and Code Snippets
Community Discussions
Trending Discussions on coolkey
QUESTION
I am trying to extract the following from a PIV Smartcard:
- Subject Common Name
- Certificate Subject Alt Name / Microsoft Principal Name
I am using RedHat 6 (eventually 7) and CoolKey as my PKCS11 module.
I need a way to extract this information via code without requiring the smartcard pin, be it from shell commands or a smartcard library. Currently I can get the Common Name by using the shell command 'pkcs11-tools --module -T' so the Subject Alt Name is truly what I am after, but I would like to find a better way to get the Common Name if available.
I know this information is available without entering the pin as I can view it all in the included Smartcard Manager on RHEL (esc). I have a certificate chain of root, intermediate, and subordinate if that matters.
My thoughts are I have to extract the certificate from the card, verify that certificate with my local CAs, and then decrypt it. I have spent days reading documentation on APDUs, smartcards, and openssl and have gotten nowhere.
edit view of RHEL smart card manager:
This is what the smart card viewer shows when you open the card and view the details. The Microsoft Principal Name is what I'm looking to extract from the card, as well as the "common name" which is displayed in the Hierarchy portion as well as other spots, shown by the red text.
I actually have since switched to using pkcs15-tool, as pkcs11-tool cutoff longer common names (you can see this in the title bar of the screenshot, same issue). Output of: 'pkcs15-tool --list-info'
...ANSWER
Answered 2020-Sep-10 at 18:52I was able to get the common name and UPN/Certificate Alt Name by using Java bouncycastle and the iaik pkcs11 wrapper.
QUESTION
I was wondering how I could split a String by :
but not ::
using String#split(String)
I am using Java if it makes a difference.
I looked around a lot and I couldn't find anything, and I'm not familiar with Regex...
Example:
coolKey:cool::value
should return ["coolKey", "cool::value"]
cool::key:cool::value
should return ["cool::key", "cool::value"]
ANSWER
Answered 2020-Sep-07 at 23:41You could try splitting on (?:
QUESTION
I know there is gather_()
but its not working with matches
and so ...
ANSWER
Answered 2018-Feb-28 at 19:46You need to unquote the dynamic key argument, either with the UQ function or with the equivalent double-bang notation:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install coolkey
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page