|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectccs.beetree.BeeObject
ccs.cdb.CDBObject
ccs.cpc.impl.CpcLicence
public class CpcLicence
Registration information for this Checkpoint installation. Who owns it, basically.
Field Summary | |
---|---|
java.lang.String |
licenseKey
The license key. |
static java.lang.String |
LICENSEVERSION
The version for licensing purposes. |
static int |
NHASH
The registration contains 112 bits of hash (14 bytes). |
static int |
NSALT
The registration contains 48 bits of salt (6 bytes). |
java.lang.String |
ownerOrg
The organisation this is registered to. |
java.lang.String |
ownerPerson
The person this is registered to. |
Fields inherited from class ccs.cdb.CDBObject |
---|
clone, key, marshalVersion, owner |
Fields inherited from class ccs.beetree.BeeObject |
---|
cipher, encodedLength, isBodiless, isForceDirectDecrypt, isZip, slack |
Constructor Summary | |
---|---|
CpcLicence()
|
Method Summary | |
---|---|
void |
check()
Check that the registration key is valid. |
protected void |
cpmarshal(java.io.DataOutputStream dest)
override this to marshal your data, just like marshal . |
protected void |
cpunmarshal(java.io.DataInputStream src,
int marshalver)
override this to unmarshal your data, just like unmarshal . |
protected byte[] |
generateMAC(byte[] salt)
Generate the hash value. |
boolean |
isValid()
Whether the registration key is valid. |
Methods inherited from class ccs.cdb.CDBObject |
---|
canChangeKeyProgrammatically, canDeleteProgrammatically, canUpdateProgrammatically, cpgetKey, cpgetMarshalledLength, cppreMarshal, cppreUnmarshal, cpsetKey, getCDB, getKey, getMarshalledLength, marshal, preMarshal, preUnmarshal, setCDB, setKey, transientMarshal, transientUnmarshal, unmarshal |
Methods inherited from class ccs.beetree.BeeObject |
---|
lock, unlock |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int NSALT
public static final int NHASH
public static final java.lang.String LICENSEVERSION
public java.lang.String ownerPerson
public java.lang.String ownerOrg
public java.lang.String licenseKey
Constructor Detail |
---|
public CpcLicence()
Method Detail |
---|
public boolean isValid()
public void check()
java.lang.IllegalArgumentException
- If the registration key is no good.protected byte[] generateMAC(byte[] salt)
salt
- The first NSALT bytes of this are used as salt.
protected void cpmarshal(java.io.DataOutputStream dest) throws java.io.IOException
ccs.cdb.CDBObject
marshal
.
The data will be in the object's fields when this is called (rather than
within any UI objects).
cpmarshal
in class ccs.cdb.CDBObject
dest
- The stream to marshal onto.
java.io.IOException
- If this breaks (breaks the CDB too).protected void cpunmarshal(java.io.DataInputStream src, int marshalver) throws java.io.IOException
ccs.cdb.CDBObject
unmarshal
.
cpunmarshal
in class ccs.cdb.CDBObject
src
- The stream to unmarshal frommarshalver
- The marshal version of the data in src - i.e. the
version of this class which wrote the data. This may be
different from the current marshalVersion
. If so (i.e. the
stored data is the wrong version) your method should allow for it.
This allows comparatively painless data migration between versions of
your objects.
java.io.IOException
- if this breaks (breaks the CDB too).
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |