public boolean [ ] getKeyUsageMappedBits ( ) { KeyUsageExtension keyUsage = new KeyUsageExtension ( ) ; Boolean val = Boolean . TRUE ; try { if ( isSet ( getPosition ( SSL_CLIENT ) ) || isSet ( getPosition ( S_MIME ) ) || isSet ( getPosition ( OBJECT_SIGNING ) ) ) keyUsage . set ( KeyUsageExtension . DIGITAL_SIGNATURE , val ) ; if ( isSet ( getPosition ( SSL_SERVER ) ) ) keyUsage . set ( KeyUsageExtension . KEY_ENCIPHERMENT , val ) ; if ( isSet ( getPosition ( SSL_CA ) ) || isSet ( getPosition ( S_MIME_CA ) ) || isSet ( getPosition ( OBJECT_SIGNING_CA ) ) ) keyUsage . set ( KeyUsageExtension . KEY_CERTSIGN , val ) ; } catch ( IOException e ) { } return keyUsage . getBits ( ) ; }
Get a boolean array representing the bits of this extension as it maps to the KeyUsage extension .