for safety, always create a session config with a destination
This commit is contained in:
@ -47,7 +47,10 @@ public class SessionConfig extends DataStructureImpl {
|
|||||||
private final static long OFFSET_VALIDITY = 30 * 1000;
|
private final static long OFFSET_VALIDITY = 30 * 1000;
|
||||||
|
|
||||||
public SessionConfig() {
|
public SessionConfig() {
|
||||||
_destination = null;
|
this(null);
|
||||||
|
}
|
||||||
|
public SessionConfig(Destination dest) {
|
||||||
|
_destination = dest;
|
||||||
_signature = null;
|
_signature = null;
|
||||||
_creationDate = new Date(Clock.getInstance().now());
|
_creationDate = new Date(Clock.getInstance().now());
|
||||||
_options = null;
|
_options = null;
|
||||||
@ -61,14 +64,6 @@ public class SessionConfig extends DataStructureImpl {
|
|||||||
return _destination;
|
return _destination;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Specify the destination for which this session is supposed to connect
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
public void setDestination(Destination dest) {
|
|
||||||
_destination = dest;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determine when this session was authorized by the destination (so we can
|
* Determine when this session was authorized by the destination (so we can
|
||||||
* prevent replay attacks)
|
* prevent replay attacks)
|
||||||
|
Reference in New Issue
Block a user