|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectopencard.opt.security.CredentialBag
public class CredentialBag
A container for stores that hold cryptographic credentials.
Smartcards may protect access to the data stored on them by means of
cryptography. Applications have to provide cryptographic credentials
to the card services they are using, so the services can overcome this
protection. The credentials for a particular smartcard are collected
in instances of class CredentialStore. These stores are
collected in instances of this class.
An application that supports different smartcards will set up a store
for each of the cards. Then, it puts all these stores into a bag. This
bag is passed to the card service that is used to access a particular
smartcard that has been inserted. The card service will pick the right
store from the bag and use the credentials in that store. That way, the
application does not have to worry about which particular card it is
currently working with.
Credential
,
CredentialStore
,
CardService
Field Summary | |
---|---|
protected java.util.Vector |
credentialBag
The container to hold the CredentialStore objects. |
Constructor Summary | |
---|---|
CredentialBag()
Instantiates an empty credential bag. |
Method Summary | |
---|---|
void |
addCredentialStore(CredentialStore credstore)
Adds a store to this bag. |
CredentialStore |
getCredentialStore(CardID cardID,
java.lang.Class clazz)
Retrieves a single store from this bag. |
CredentialStore[] |
getCredentialStores(CardID cardID,
java.lang.Class clazz)
Retrieves stores from this bag. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.util.Vector credentialBag
Constructor Detail |
---|
public CredentialBag()
Method Detail |
---|
public void addCredentialStore(CredentialStore credstore)
credstore
- The CredentialStore object to be added.public final CredentialStore getCredentialStore(CardID cardID, java.lang.Class clazz)
cardID
- the identifier of the smartcard to supportclazz
- the type of the store to return.
Use CredentialStore.class if the
type does not matter.
getCredentialStores(opencard.core.terminal.CardID, java.lang.Class)
public final CredentialStore[] getCredentialStores(CardID cardID, java.lang.Class clazz)
cardID
- the identifier of the smartcard to supportclazz
- the type of the store to return.
Use CredentialStore.class if the
type does not matter.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |