C# Class Org.BouncyCastle.Bcpg.OpenPgp.PgpSecretKeyRingBundle

Often a PGP key ring file is made up of a succession of master/sub-key key rings. If you want to read an entire secret key file in one hit this is the class for you.
Afficher le fichier Open project: nonorganic/dssnet Class Usage Examples

Private Properties

Свойство Type Description
PgpSecretKeyRingBundle System

Méthodes publiques

Méthode Description
AddSecretKeyRing ( PgpSecretKeyRingBundle bundle, PgpSecretKeyRing secretKeyRing ) : PgpSecretKeyRingBundle

Return a new bundle containing the contents of the passed in bundle and the passed in secret key ring.

Contains ( long keyID ) : bool

Return true if a key matching the passed in key ID is present, false otherwise.

Encode ( Stream outStr ) : void
GetEncoded ( ) : byte[]
GetKeyRings ( ) : IEnumerable

Allow enumeration of the secret key rings making up this collection.

GetKeyRings ( string userId ) : IEnumerable

Allow enumeration of the key rings associated with the passed in userId.

GetKeyRings ( string userId, bool matchPartial ) : IEnumerable

Allow enumeration of the key rings associated with the passed in userId.

GetKeyRings ( string userId, bool matchPartial, bool ignoreCase ) : IEnumerable

Allow enumeration of the key rings associated with the passed in userId.

GetSecretKey ( long keyId ) : PgpSecretKey

Return the PGP secret key associated with the given key id.

GetSecretKeyRing ( long keyId ) : PgpSecretKeyRing

Return the secret key ring which contains the key referred to by keyId

PgpSecretKeyRingBundle ( IEnumerable e ) : System
PgpSecretKeyRingBundle ( Stream inputStream ) : System

Build a PgpSecretKeyRingBundle from the passed in input stream.

PgpSecretKeyRingBundle ( byte encoding ) : System
RemoveSecretKeyRing ( PgpSecretKeyRingBundle bundle, PgpSecretKeyRing secretKeyRing ) : PgpSecretKeyRingBundle

Return a new bundle containing the contents of the passed in bundle with the passed in secret key ring removed.

Private Methods

Méthode Description
PgpSecretKeyRingBundle ( IDictionary secretRings, IList order ) : System

Method Details

AddSecretKeyRing() public static méthode

Return a new bundle containing the contents of the passed in bundle and the passed in secret key ring.
If the keyId for the passed in key ring is already present.
public static AddSecretKeyRing ( PgpSecretKeyRingBundle bundle, PgpSecretKeyRing secretKeyRing ) : PgpSecretKeyRingBundle
bundle PgpSecretKeyRingBundle The PgpSecretKeyRingBundle the key ring is to be added to.
secretKeyRing PgpSecretKeyRing The key ring to be added.
Résultat PgpSecretKeyRingBundle

Contains() public méthode

Return true if a key matching the passed in key ID is present, false otherwise.
public Contains ( long keyID ) : bool
keyID long key ID to look for.
Résultat bool

Encode() public méthode

public Encode ( Stream outStr ) : void
outStr Stream
Résultat void

GetEncoded() public méthode

public GetEncoded ( ) : byte[]
Résultat byte[]

GetKeyRings() public méthode

Allow enumeration of the secret key rings making up this collection.
public GetKeyRings ( ) : IEnumerable
Résultat IEnumerable

GetKeyRings() public méthode

Allow enumeration of the key rings associated with the passed in userId.
public GetKeyRings ( string userId ) : IEnumerable
userId string The user ID to be matched.
Résultat IEnumerable

GetKeyRings() public méthode

Allow enumeration of the key rings associated with the passed in userId.
public GetKeyRings ( string userId, bool matchPartial ) : IEnumerable
userId string The user ID to be matched.
matchPartial bool If true, userId need only be a substring of an actual ID string to match.
Résultat IEnumerable

GetKeyRings() public méthode

Allow enumeration of the key rings associated with the passed in userId.
public GetKeyRings ( string userId, bool matchPartial, bool ignoreCase ) : IEnumerable
userId string The user ID to be matched.
matchPartial bool If true, userId need only be a substring of an actual ID string to match.
ignoreCase bool If true, case is ignored in user ID comparisons.
Résultat IEnumerable

GetSecretKey() public méthode

Return the PGP secret key associated with the given key id.
public GetSecretKey ( long keyId ) : PgpSecretKey
keyId long The ID of the secret key to return.
Résultat PgpSecretKey

GetSecretKeyRing() public méthode

Return the secret key ring which contains the key referred to by keyId
public GetSecretKeyRing ( long keyId ) : PgpSecretKeyRing
keyId long The ID of the secret key
Résultat PgpSecretKeyRing

PgpSecretKeyRingBundle() public méthode

public PgpSecretKeyRingBundle ( IEnumerable e ) : System
e IEnumerable
Résultat System

PgpSecretKeyRingBundle() public méthode

Build a PgpSecretKeyRingBundle from the passed in input stream.
If a problem parsing the stream occurs. If an object is encountered which isn't a PgpSecretKeyRing.
public PgpSecretKeyRingBundle ( Stream inputStream ) : System
inputStream Stream Input stream containing data.
Résultat System

PgpSecretKeyRingBundle() public méthode

public PgpSecretKeyRingBundle ( byte encoding ) : System
encoding byte
Résultat System

RemoveSecretKeyRing() public static méthode

Return a new bundle containing the contents of the passed in bundle with the passed in secret key ring removed.
If the keyId for the passed in key ring is not present.
public static RemoveSecretKeyRing ( PgpSecretKeyRingBundle bundle, PgpSecretKeyRing secretKeyRing ) : PgpSecretKeyRingBundle
bundle PgpSecretKeyRingBundle The PgpSecretKeyRingBundle the key ring is to be removed from.
secretKeyRing PgpSecretKeyRing The key ring to be removed.
Résultat PgpSecretKeyRingBundle