com.atlassian.security.auth.trustedapps
Class DefaultCurrentApplication
java.lang.Object
com.atlassian.security.auth.trustedapps.DefaultCurrentApplication
- All Implemented Interfaces:
- Application, CurrentApplication
- public class DefaultCurrentApplication
- extends java.lang.Object
- implements CurrentApplication
|
Field Summary |
protected java.lang.String |
id
|
protected java.security.PrivateKey |
privateKey
|
protected java.security.PublicKey |
publicKey
|
|
Method Summary |
EncryptedCertificate |
encode(java.lang.String userName)
Returned String can be used as a certificate to talk
to the server that trusts this application. |
java.lang.String |
getID()
|
java.security.PublicKey |
getPublicKey()
Public key of this application. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
id
protected final java.lang.String id
publicKey
protected final java.security.PublicKey publicKey
privateKey
protected final java.security.PrivateKey privateKey
DefaultCurrentApplication
public DefaultCurrentApplication(EncryptionProvider encryptionProvider,
java.security.PublicKey publicKey,
java.security.PrivateKey privateKey,
java.lang.String id)
DefaultCurrentApplication
public DefaultCurrentApplication(java.security.PublicKey publicKey,
java.security.PrivateKey privateKey,
java.lang.String id)
encode
public EncryptedCertificate encode(java.lang.String userName)
- Returned String can be used as a certificate to talk
to the server that trusts this application. I.e. the ID of this app and the certificate go into the following header parameters:
CurrentApplication.HEADER_TRUSTED_APP_CERT
CurrentApplication.HEADER_TRUSTED_APP_ID
- Specified by:
encode in interface CurrentApplication
- Returns:
- encrypted certificate representing this application
getID
public java.lang.String getID()
- Specified by:
getID in interface Application
- Returns:
- Unique ID representing this application
getPublicKey
public java.security.PublicKey getPublicKey()
- Description copied from interface:
Application
- Public key of this application. Public key will be sent to the remote server when requesting it to trust this application.
- Specified by:
getPublicKey in interface Application
Copyright © 2009 Atlassian Pty Ltd. All Rights Reserved.