|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.threerings.io.SimpleStreamableObject
com.threerings.presents.net.Message
com.threerings.presents.net.UpstreamMessage
com.threerings.presents.net.AuthRequest
com.threerings.presents.net.AESAuthRequest
public class AESAuthRequest
Sends an AES encrypted auth request to the server. It assumes that
SecureUtil.ciphersSupported(java.security.PrivateKey) has succeeded.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.threerings.io.Streamable |
|---|
Streamable.Closure |
| Field Summary | |
|---|---|
protected Credentials |
_clearCreds
Our unencrypted credentials. |
protected byte[] |
_contents
Our encrypted contents. |
protected byte[] |
_key
Our encryption key. |
| Fields inherited from class com.threerings.presents.net.AuthRequest |
|---|
_bootGroups, _creds, _version, _zone |
| Fields inherited from class com.threerings.presents.net.UpstreamMessage |
|---|
_nextMessageId, messageId |
| Fields inherited from class com.threerings.presents.net.Message |
|---|
received |
| Constructor Summary | |
|---|---|
AESAuthRequest()
Zero argument constructor used when unserializing an instance. |
|
AESAuthRequest(byte[] key,
Credentials creds,
String version,
String[] bootGroups)
Constructs a auth request with the supplied credentials and client version information. |
|
| Method Summary | |
|---|---|
static AuthRequest |
createAuthRequest(Credentials creds,
String version,
String[] bootGroups,
boolean requireSecureAuth)
Creates an auth request, secured if able, unsecured if not. |
static AuthRequest |
createAuthRequest(Credentials creds,
String version,
String[] bootGroups,
boolean requireSecureAuth,
PublicKeyCredentials pkcreds,
SecureResponse resp)
Creates an auth request, secured if able, unsecured if not. |
void |
decrypt(byte[] key)
Decrypts the request after transmission. |
Credentials |
getCredentials()
Returns a reference to the credentials provided with this request. |
byte[] |
getSecret()
Returns a shared secret key used for sending encrypted data to the client. |
void |
readObject(ObjectInputStream in)
Read in our encrypted contents. |
String |
toString()
|
void |
writeObject(ObjectOutputStream out)
A customized AES encrypting write object. |
| Methods inherited from class com.threerings.presents.net.AuthRequest |
|---|
getBootGroups, getTimeZone, getVersion |
| Methods inherited from class com.threerings.presents.net.UpstreamMessage |
|---|
nextMessageId |
| Methods inherited from class com.threerings.presents.net.Message |
|---|
getTransport, noteActualTransport, setTransport |
| Methods inherited from class com.threerings.io.SimpleStreamableObject |
|---|
toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected transient byte[] _key
protected transient byte[] _contents
protected transient Credentials _clearCreds
| Constructor Detail |
|---|
public AESAuthRequest()
public AESAuthRequest(byte[] key,
Credentials creds,
String version,
String[] bootGroups)
| Method Detail |
|---|
public static AuthRequest createAuthRequest(Credentials creds,
String version,
String[] bootGroups,
boolean requireSecureAuth)
public static AuthRequest createAuthRequest(Credentials creds,
String version,
String[] bootGroups,
boolean requireSecureAuth,
PublicKeyCredentials pkcreds,
SecureResponse resp)
public Credentials getCredentials()
AuthRequest
getCredentials in class AuthRequestpublic byte[] getSecret()
AuthRequest
getSecret in class AuthRequestpublic String toString()
toString in class AuthRequest
public void decrypt(byte[] key)
throws IOException,
ClassNotFoundException
IOException
ClassNotFoundException
public void writeObject(ObjectOutputStream out)
throws IOException
IOException
public void readObject(ObjectInputStream in)
throws IOException,
ClassNotFoundException
readObject in class AuthRequestIOException
ClassNotFoundException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||