ERUCES::TEACLEntry
#include <teacl.h>
The TEACLEntry class manages access control list (ACL) entries.
The TEACLEntry class represents an entry in a TTag access control list (ACL). Many TEACLEntry objects maintain a relationship with a single TEACLInfo object.
Inheritance
- Inherits ERUCES::TEUpdatableObject
Private Attrib
| Type | Name | Description |
|---|---|---|
| bool | m_bOwner |
Public Member Functions
| Member | Description |
|---|---|
TEACLEntry() | The TEACLEntry constructor is the default class constructor. |
TEACLEntry(const TEACLEntry &) | |
~TEACLEntry() | The TEACLEntry destructor is the class destructor. |
void setPrincipalId(te_oid id) | The setPrincipalId method sets a unique principal identifier. |
te_oid getPrincipalId() const | The getPrincipalId method gets a principal identifier. |
void setSystemID(uint32_t sid) | The setSystemId method sets a unique system identifier. |
uint32_t getSystemID() const | The getSystemId method gets a system identifier. |
void setMaxUsage(int32_t maxUse) | The setMaxUsage method sets the maximum number of times a user associated with a TEACLEntry object may access data using a specific key. |
int32_t getMaxUsage() const | The getMaxUsage method retrieves a number representing the maximum number of times a specific user may use a key to access data. |
void setACLRight(uint32_t right) | The setACLRight method sets an access control list right for a TEACLEntry object. |
uint32_t getACLRight() const | The getACLRight method retrieves an access control list right assigned to a TEACLEntry object. |
void setACLId(te_oid id) | The setACLId method sets a unique access control list identifier. |
te_oid getACLId() const | The getACLId method gets an access control list identifier. |
void setCreationTimestamp(time_t t) | The setCreationTimestamp method sets a timestamp indicating when a TEACLEntry object was created. |
time_t getCreationTimestamp() const | The getCreationTimestamp method gets the timestamp issued when a TEACLEntry object was created. |
void setEndTimestamp(time_t t) | The setEndTimestamp method sets a timestamp indicating when a TEACEntry object expires. |
time_t getEndTimestamp() const | The getEndTimestamp method gets a timestamp indicating when access to a TEACLEntry object ends. |
void setStartTimestamp(time_t t) | The setStartTimestamp method sets a timestamp indicating when access to a TEACLEntry object starts. |
time_t getStartTimestamp() const | The getStartTimestamp method gets a timestamp indicating when access to a TEACLEntry object starts. |
void setUserRight(uint32_t right) | The setUserRight method sets a user right. |
uint32_t getUserRight() const | The getUserRight method gets a user right; internal use only. |
TEObject * clone() const | The clone method clones a TEACLEntry object. |
bool operator==(const TEACLEntry &entry) const | The == operator compares two TEACLEntry objects. |
Private Func
| Member | Description |
|---|---|
TEACLEntry(const ACLEntry *) |
Member Function Documentation
TEACLEntry()
The TEACLEntry constructor is the default class constructor.
TEACLEntry(const TEACLEntry &)
The TEACLEntry constructor copies an object.
Parameters
| Parameter | Description |
|---|---|
& | The object being copied. |
~TEACLEntry()
The TEACLEntry destructor is the class destructor.
void setPrincipalId(te_oid id)
The setPrincipalId method sets a unique principal identifier.
Parameters
| Parameter | Description |
|---|---|
id | The principal ID to be set. |
te_oid getPrincipalId() const
The getPrincipalId method gets a principal identifier.
Returns: Returns a principal ID.
void setSystemID(uint32_t sid)
The setSystemId method sets a unique system identifier.
Parameters
| Parameter | Description |
|---|---|
sid | The system ID to be set. |
uint32_t getSystemID() const
The getSystemId method gets a system identifier.
Returns: Returns a system ID.
void setMaxUsage(int32_t maxUse)
The setMaxUsage method sets the maximum number of times a user associated with a TEACLEntry object may access data using a specific key.
Parameters
| Parameter | Description |
|---|---|
maxUse | The maximum number of times a user associated with a TEACLEntry object may access data using a specific key; if value=-1, the user has unlimited use of the key. |
int32_t getMaxUsage() const
The getMaxUsage method retrieves a number representing the maximum number of times a specific user may use a key to access data.
Returns: Returns the maximum number of times a user associated with a TEACLEntry object may access data using a specific key; if value = -1, the user has unlimited use of the key.
void setACLRight(uint32_t right)
The setACLRight method sets an access control list right for a TEACLEntry object.
All possible values: enum ACLOP ACL_READ = 0x00000001 Principal has ability to perform decryption using the TTag. ACL_WRITE = 0x00000002 Principal can perform encryption and decryption using the TTag. Principal to add other principals to an ACL for the TTag. ACL_OWNER = 0x00000004 Principal is the owner of the TTag. Set automatically. ACL_CHECKOUT = 0x00000008 (For internal use only.) ACL_TEMPORARY = 0x00000010 (For internal use only.) ACL_PURGE = 0x00000020 (For internal use only.) ACL_DISABLE = 0x00000040 (For internal use only.) ACL_NONREMOVABLE= 0x00000080 (For internal use only.) ACL_TEMPLATE_READ = 0x00000100 (For internal use only.) ACL_TEMPLATE_WRITE = 0x00000200 (For internal use only.) ACL_MANDATORY_GROUP = 0x00000400 The principal is a mandatory group. Membership is required to use the TTag. ACL_HOST_MATRIX = 0x00000800 (For internal use only.)
Parameters
| Parameter | Description |
|---|---|
right | The ACL right to be set; typically: read = 0x00000001, write = 0x00000002. |
uint32_t getACLRight() const
The getACLRight method retrieves an access control list right assigned to a TEACLEntry object.
All possible values: enum ACLOP ACL_READ = 0x00000001 Principal has ability to perform decryption using the TTag. ACL_WRITE = 0x00000002 Principal can perform encryption and decryption using the TTag. Principal to add other principals to an ACL for the TTag. ACL_OWNER = 0x00000004 Principal is the owner of the TTag. Set automatically. ACL_CHECKOUT = 0x00000008 (For internal use only.) ACL_TEMPORARY = 0x00000010 (For internal use only.) ACL_PURGE = 0x00000020 (For internal use only.) ACL_DISABLE = 0x00000040 (For internal use only.) ACL_NONREMOVABLE= 0x00000080 (For internal use only.) ACL_TEMPLATE_READ = 0x00000100 (For internal use only.) ACL_TEMPLATE_WRITE = 0x00000200 (For internal use only.) ACL_MANDATORY_GROUP = 0x00000400 The principal is a mandatory group. Membership is required to use the TTag. ACL_HOST_MATRIX = 0x00000800 (For internal use only.)
Returns: Returns an ACL right.
void setACLId(te_oid id)
The setACLId method sets a unique access control list identifier.
Parameters
| Parameter | Description |
|---|---|
id | The TEACLInfo ID to be set. |
te_oid getACLId() const
The getACLId method gets an access control list identifier.
Returns: Returns TEACLInfo object's ID.
void setCreationTimestamp(time_t t)
The setCreationTimestamp method sets a timestamp indicating when a TEACLEntry object was created.
The timestamp may be reset by the Key Service when the object is actually created.
Parameters
| Parameter | Description |
|---|---|
t | A timestamp indicating when a TEACLEntry object was created. |
time_t getCreationTimestamp() const
The getCreationTimestamp method gets the timestamp issued when a TEACLEntry object was created.
Returns: Returns a TEACEntry object's creation timestamp.
void setEndTimestamp(time_t t)
The setEndTimestamp method sets a timestamp indicating when a TEACEntry object expires.
Parameters
| Parameter | Description |
|---|---|
t | A timestamp indicating when a TEACLEntry object expires. |
time_t getEndTimestamp() const
The getEndTimestamp method gets a timestamp indicating when access to a TEACLEntry object ends.
Returns: Returns a timestamp indicating when access to a TEACLEntry object expires.
void setStartTimestamp(time_t t)
The setStartTimestamp method sets a timestamp indicating when access to a TEACLEntry object starts.
Parameters
| Parameter | Description |
|---|---|
t | A timestamp indicating when access to a TEACLEntry object starts. |
time_t getStartTimestamp() const
The getStartTimestamp method gets a timestamp indicating when access to a TEACLEntry object starts.
Returns: Returns a timestamp indicating when access to a TEACLEntry object starts.
void setUserRight(uint32_t right)
The setUserRight method sets a user right.
Parameters
| Parameter | Description |
|---|---|
right | The user right to be set. |
uint32_t getUserRight() const
The getUserRight method gets a user right; internal use only.
Returns: Returns a user right.
TEObject * clone() const
The clone method clones a TEACLEntry object.
Returns: Returns a cloned TEACLEntry object.
bool operator==(const TEACLEntry &entry) const
The == operator compares two TEACLEntry objects.
The criteria include ACL ID, principal ID and system ID. Two ACLEntry objects are the same if their system ID, principal ID and ACL ID are the same.
Parameters
| Parameter | Description |
|---|---|
entry | A TEACLEntry object to be compared with the current TEACLEntry object. |
Returns: Returns a boolean value indicating if the two objects are equivalent; the objects are the same if their system ID, principal ID and ACL ID are the same; TRUE = objects are the same, FALSE = objects are not the same.
TEACLEntry(const ACLEntry *)
Constructor for internal use