|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SESecurityManager
Field Summary | |
---|---|
static int |
BLOCK_ENCRYPTION_AES
|
static int |
BLOCK_ENCRYPTION_NONE
|
Method Summary | |
---|---|
void |
addCertificateListener(CertificateListener listener)
|
void |
addPasswordListener(PasswordListener listener)
|
byte[] |
calculateSHA1(byte[] data_in)
returns the SHA1 hash of the input data |
Certificate |
createSelfSignedCertificate(String alias,
String cert_dn,
int strength)
creates and installs a certificate capable of supporting SSL of type MD5withRSA |
SEPublicKey |
decodePublicKey(byte[] encoded)
|
byte[] |
getIdentity()
Gets this azureus instance's unique random identity |
KeyStore |
getKeyStore()
|
SEPublicKey |
getPublicKey(int key_type,
String reason_resource)
Gets the public key for this az instance of the supplied key type |
GenericMessageConnection |
getSTSConnection(GenericMessageConnection connection,
SEPublicKey my_public_key,
SEPublicKeyLocator key_locator,
String reason_resource,
int block_encryption)
Returns a proxy generic STS connection for incoming connection requests |
KeyStore |
getTrustStore()
|
SSLSocketFactory |
installServerCertificate(URL url)
Installs the SSL certificate necessary to support the connection |
void |
removeCertificateListener(CertificateListener listener)
|
void |
removePasswordListener(PasswordListener listener)
|
void |
runWithAuthenticator(Authenticator authenticator,
Runnable task)
|
Field Detail |
---|
static final int BLOCK_ENCRYPTION_NONE
static final int BLOCK_ENCRYPTION_AES
Method Detail |
---|
void runWithAuthenticator(Authenticator authenticator, Runnable task)
void addPasswordListener(PasswordListener listener)
void removePasswordListener(PasswordListener listener)
void addCertificateListener(CertificateListener listener)
void removeCertificateListener(CertificateListener listener)
byte[] calculateSHA1(byte[] data_in)
data_in
-
SSLSocketFactory installServerCertificate(URL url)
url
- KeyStore getKeyStore() throws Exception
Exception
KeyStore getTrustStore() throws Exception
Exception
Certificate createSelfSignedCertificate(String alias, String cert_dn, int strength) throws Exception
alias
- alias - e.g. "mycert"cert_dn
- dn for the cert e.g. "CN=fred,OU=wap,O=wip,L=here,ST=there,C=GB"strength
- keyt strength - e.g. 1024
Exception
byte[] getIdentity()
SEPublicKey getPublicKey(int key_type, String reason_resource) throws Exception
key_type
- see KEY_TYPE_x constants in SEPublicKeyreason_resource
- a message text resource giving the reason for the key being required
Exception
SEPublicKey decodePublicKey(byte[] encoded) throws Exception
Exception
GenericMessageConnection getSTSConnection(GenericMessageConnection connection, SEPublicKey my_public_key, SEPublicKeyLocator key_locator, String reason_resource, int block_encryption) throws Exception
connection
- my_public_key
- key_locator
-
Exception
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |