org.acplt.oncrpc.server
Class OncRpcServerAuthShort
java.lang.Object
|
+--org.acplt.oncrpc.server.OncRpcServerAuth
|
+--org.acplt.oncrpc.server.OncRpcServerAuthShort
- public final class OncRpcServerAuthShort
- extends OncRpcServerAuth
The OncRpcServerAuthShort
class handles all protocol issues
of the ONC/RPC authentication AUTH_SHORT
on the server
side.
Field Summary |
private byte[] |
shorthandCred
Contains the shorthand credential sent by the caller. |
private byte[] |
shorthandVerf
Contains the shorthand authentication verifier (credential) to return
to the caller to be used with the next ONC/RPC calls. |
Methods inherited from class java.lang.Object |
,
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
toString,
wait,
wait,
wait |
shorthandCred
private byte[] shorthandCred
- Contains the shorthand credential sent by the caller.
shorthandVerf
private byte[] shorthandVerf
- Contains the shorthand authentication verifier (credential) to return
to the caller to be used with the next ONC/RPC calls.
OncRpcServerAuthShort
public OncRpcServerAuthShort(XdrDecodingStream xdr)
throws OncRpcException,
java.io.IOException
- Constructs an
OncRpcServerAuthShort
object and pulls its
state off an XDR stream.
- Parameters:
xdr
- XDR stream to retrieve the object state from.- Throws:
- OncRpcException - if an ONC/RPC error occurs.
- java.io.IOException - if an I/O error occurs.
getAuthenticationType
public final int getAuthenticationType()
- Returns the type (flavor) of authentication
used.
- Returns:
- Authentication type used by this authentication object.
- Overrides:
- getAuthenticationType in class OncRpcServerAuth
getShorthandCred
public final byte[] getShorthandCred()
- Returns the shorthand credential sent by the caller.
setShorthandVerifier
public final void setShorthandVerifier(byte[] shorthandVerf)
- Sets shorthand verifier to be sent back to the caller. The caller then
can use this shorthand verifier as the new credential with the next
ONC/RPC calls. If you don't set the verifier or set it to
null
, then the verifier returned to the caller will be
of type AUTH_NONE
.
getShorthandVerifier
public final byte[] getShorthandVerifier()
- Returns the shorthand verifier to be sent back to the caller.
xdrDecodeCredVerf
public final void xdrDecodeCredVerf(XdrDecodingStream xdr)
throws OncRpcException,
java.io.IOException
- Decodes -- that is: deserializes -- an ONC/RPC authentication object
(credential & verifier) on the server side.
- Throws:
- OncRpcException - if an ONC/RPC error occurs.
- java.io.IOException - if an I/O error occurs.
- Overrides:
- xdrDecodeCredVerf in class OncRpcServerAuth
xdrEncodeVerf
public final void xdrEncodeVerf(XdrEncodingStream xdr)
throws OncRpcException,
java.io.IOException
- Encodes -- that is: serializes -- an ONC/RPC authentication object
(its verifier) on the server side.
- Throws:
- OncRpcException - if an ONC/RPC error occurs.
- java.io.IOException - if an I/O error occurs.
- Overrides:
- xdrEncodeVerf in class OncRpcServerAuth