class RDRMRightsClient : public RSessionBase |
This class is the client side interface for DRM3 Rights Server. This class can be used to access the DRM Rights Database.
Private Member Functions | |
---|---|
RDRMRightsClient (const RDRMRightsClient &) | |
void | FileToListL ( RFs &, const TDesC &, RPointerArray < CDRMPermission > &) |
void | URIFileToArrayL ( RFs &, const TDesC &, RPointerArray < HBufC8 > &) |
RDRMRightsClient & | operator= (const RDRMRightsClient &) |
Inherited Enumerations | |
---|---|
RHandleBase:TAttributes | |
RSessionBase:TAttachMode |
Private Attributes | |
---|---|
TAny * | iPtr |
Inherited Attributes | |
---|---|
RHandleBase::iHandle |
RDRMRightsClient | ( | const RDRMRightsClient & | ) | [private] |
const RDRMRightsClient & |
IMPORT_C TInt | AddDomainRO | ( | const TDesC8 & | aRoId, |
const TDesC8 & | aXmlData | |||
) |
AddDomainRO
Add the xml representation of the domain RO to the database
IMPORT_C TInt | AddProtectedRecord | ( | const TDesC8 & | aProtectedCek, |
TBool | aDomainRecord, | |||
const CDRMPermission & | aRightsObject, | |||
const TDesC8 & | aCID, | |||
TDRMUniqueID & | aID | |||
) |
const TDesC8 & aProtectedCek | wrapped CEK |
TBool aDomainRecord | |
const CDRMPermission & aRightsObject | Rights object to be added. |
const TDesC8 & aCID | Content-ID. |
TDRMUniqueID & aID |
IMPORT_C TInt | AddRecord | ( | const TDesC8 & | aCEK, |
const CDRMPermission & | aRightsObject, | |||
const TDesC8 & | aCID, | |||
TDRMUniqueID & | aID | |||
) |
const TDesC8 & aCEK | CEK. |
const CDRMPermission & aRightsObject | Rights object to be added. |
const TDesC8 & aCID | Content-ID. |
TDRMUniqueID & aID |
IMPORT_C TInt | AddToCache | ( | const TDesC8 & | aID, |
const TTime & | aTime | |||
) |
AddToReplayCache
Adds an entry to Replay Cache. Note! Does not check whether the entry is already in cache. Use IsInCache() first to determine whether the entry already exists.
IMPORT_C TInt | AddToCache | ( | const TDesC8 & | aID | ) |
AddToReplayCache
Adds an entry to Replay Cache. Note! Does not check whether the entry is already in cache. Use IsInCache() first to determine whether the entry already exists.
const TDesC8 & aID |
IMPORT_C TInt | CalculatePadding | ( | const TDesC8 & | aLastTwoDataBlocks | ) |
const TDesC8 & aLastTwoDataBlocks |
IMPORT_C TInt | CheckConsume | ( | const TInt | aIntent, |
const TDesC8 & | aContentID | |||
) |
IMPORT_C TInt | CheckRights | ( | const TInt | aIntent, |
const TDesC8 & | aContentID, | |||
TUint32 & | aRejection | |||
) |
This method checks whether the caller has sufficient rights over the content at this very moment.
IMPORT_C void | Close | ( | ) |
IMPORT_C TInt | Connect | ( | ) |
IMPORT_C TInt | Consume | ( | const TInt | aIntent, |
const TDesC8 & | aContentID | |||
) |
IMPORT_C TInt | DecodeRightsIssuerField | ( | const TDesC8 & | aEncoded, |
HBufC8 *& | aDecoded | |||
) |
IMPORT_C TInt | Decrypt | ( | const TDesC8 & | aIv, |
TPtr8 & | aData, | |||
TBool | aRemovePadding = EFalse | |||
) |
Decrypts data using the session key. Padding will be removed if requested.
IMPORT_C TInt | DeleteDbEntry | ( | const TDesC8 & | aContentID | ) |
const TDesC8 & aContentID | Content-ID of the rights objects to be deleted. |
IMPORT_C TInt | DeleteDbEntry | ( | const TDesC8 & | aContentID, |
const TDRMUniqueID & | aUniqueID | |||
) |
const TDesC8 & aContentID | Content-ID of the rights object. |
const TDRMUniqueID & aUniqueID | Unique ID. |
IMPORT_C TInt | DeleteDomainRO | ( | const TDesC8 & | aRoId | ) |
DeleteDomainRO
Delete the xml representation of the domain RO from the database
const TDesC8 & aRoId | : the rights object id of the domain ro |
IMPORT_C void | DeleteExpiredPermissions | ( | TRequestStatus & | aStatus | ) |
DeleteExpiredPermissions
Deletes expired permissions from the rights database Note this function will possibly take a lot of time to complete and if the drm time is not available it does not touch any time based rights
TRequestStatus & aStatus |
IMPORT_C TInt | DeleteMeteringDataL | ( | const TDesC8 & | aRiId | ) |
Deletes the metering data of the requested rights-issuer id
const TDesC8 & aRiId | : Rights-Issuer Id for which the metering data is deleted |
IMPORT_C TInt | EncodeRightsIssuerField | ( | const TDesC8 & | aOldValue, |
HBufC8 *& | aNewValue | |||
) |
IMPORT_C TInt | Encrypt | ( | const TDesC8 & | aIv, |
TPtr8 & | aData, | |||
TBool | aAddPadding = EFalse | |||
) |
Encrypts data using the session key. The data parameter must have enough space to accomodate for the addition of the paddding if it shall be added (up to 32 bytes more data)
IMPORT_C TInt | ExportContentIDList | ( | TDes & | aFileName | ) |
TDes & aFileName | Out-parameter: contains the name of the file if the method completes with KErrNone. The descriptor parameter is assumed to be large enough. The caller is responsible of deleting the file afterwards. |
IMPORT_C TInt | ExportContentIDList | ( | RPointerArray < HBufC8 > & | aCIDList | ) |
RPointerArray < HBufC8 > & aCIDList | An out-parameter: contains the Content-IDs after successful return. |
IMPORT_C TInt | ExportOrphanedContentIdList | ( | TDes & | aFileName | ) |
TDes & aFileName | Out-parameter: contains the name of the file if the method completes with KErrNone. The descriptor parameter is assumed to be large enough. The caller is responsible of deleting the file afterwards. |
IMPORT_C TInt | ExportOrphanedContentIdList | ( | RPointerArray < HBufC8 > & | aContentIdList | ) |
RPointerArray < HBufC8 > & aContentIdList | : An out-parameter: contains the Content-IDs after successful return. |
void | FileToListL | ( | RFs & | aFs, |
const TDesC & | aFileName, | |||
RPointerArray < CDRMPermission > & | aList | |||
) | [private] |
RFs & aFs | Open file server session. |
const TDesC & aFileName | Source file name |
RPointerArray < CDRMPermission > & aList | Destination list. |
IMPORT_C CDRMPermission * | GetActiveRightsL | ( | const TInt | aIntent, |
const TDesC8 & | aContentID, | |||
TUint32 & | aRejection | |||
) |
This method checks whether the caller has sufficient rights over the content at this very moment. It also returns the active rights.
IMPORT_C TInt | GetAuthenticationSeed | ( | const TDesC8 & | aContentId, |
TDes8 & | aSeed | |||
) |
IMPORT_C void | GetDBEntriesL | ( | const TDesC8 & | aId, |
RPointerArray < CDRMPermission > & | aRightsList | |||
) |
const TDesC8 & aId | Content ID. |
RPointerArray < CDRMPermission > & aRightsList | List of rights objects. |
IMPORT_C CDRMPermission * | GetDbEntryL | ( | const TDesC8 & | aContentID, |
const TDRMUniqueID & | aUniqueID | |||
) |
const TDesC8 & aContentID | Content-ID. |
const TDRMUniqueID & aUniqueID | Unique identifier. |
IMPORT_C TInt | GetDecryptionKey | ( | const TInt | aIntent, |
const TDesC8 & | aContentID, | |||
TDes8 & | aKey | |||
) |
Returns the decryption key to the content.
IMPORT_C HBufC8 * | GetDomainROL | ( | const TDesC8 & | aRoId | ) |
GetDomainROL
Get the xml representation of the domain RO from the database
const TDesC8 & aRoId | : the rights object id of the domain ro |
IMPORT_C void | GetDomainRosForCidL | ( | const TDesC8 & | aContentId, |
RPointerArray < HBufC8 > & | aRoList | |||
) |
GetDomainRoForCidL
Get the domain RO for a content ID from the database
const TDesC8 & aContentId | the content ID of the domain ro |
RPointerArray < HBufC8 > & aRoList | list of domain rights objects for this ID |
IMPORT_C TInt | GetEstimatedArrival | ( | const TDesC8 & | aContentID, |
TTimeIntervalSeconds & | aDeltaSeconds | |||
) |
GetEstimatedArrival
Gets the time in which the rights object should arrive
const TDesC8 & aContentID | : content URI |
TTimeIntervalSeconds & aDeltaSeconds | : time in seconds to wait for rights -1 if the content should have arrived |
IMPORT_C HBufC8 * | GetMeteringDataL | ( | const TDesC8 & | aRiId | ) |
Returns the metering data for the requested rights-issuer id
const TDesC8 & aRiId | : Rights-Issuer Id for which the metering data is acquired |
IMPORT_C TInt | GetName | ( | const TDesC8 & | aContentID, |
HBufC *& | aName | |||
) |
GetName
Retrieves the human-readable name associated to given content-ID
IMPORT_C void | GetRandomDataL | ( | TDes8 & | aRandomData | ) | const |
Fills the input buffer with random data. The length of the aRandomData must be set to the correct value.
TDes8 & aRandomData | : Out-parameter that will be filled with random data |
IMPORT_C TInt | GetSupportedIndividualsL | ( | RPointerArray < HBufC8 > & | aIndividuals | ) | const |
Retrieve the individuals from the Rights Server so proper comparisons of rights object validity can be performed outside of the rights server
RPointerArray < HBufC8 > & aIndividuals | : Pointer array of the individuals supported |
IMPORT_C TInt | GetUdtData | ( | TDes8 & | aUdtData | ) |
GetUdtData
Retrieves the udt data from the server
TDes8 & aUdtData |
IMPORT_C void | InitOrphanedContentIdList | ( | TBool | aPerformScan, |
TRequestStatus & | aStatus | |||
) |
Initializes the export all orphaned content ID's. When the request completes, you can ask for the contents with the ExportOrphanedContentIdList functions
TBool aPerformScan | : ETrue if file system scan needs to be performed EFalse if not |
TRequestStatus & aStatus | : Request status for the asynchronous call |
IMPORT_C TInt | InitializeGroupKey | ( | const TDesC8 & | aGroupId, |
const TDesC8 & | aGroupKey, | |||
TEncryptionMethod | aMethod | |||
) |
Similar to InitializeKeyL, but sets the key by using a group key as the input.
IMPORT_C TInt | InitializeKey | ( | const TDesC8 & | aContentId | ) |
Sets the key for subsequent encryption and decryption operations. The key is stored on the server side in the session and will be usable until the session is closed. The key will be fetched from the rights database by looking up the content ID.
const TDesC8 & aContentId | Content ID to get the key for |
IMPORT_C TInt | InitiateUdt | ( | const TDesC8 & | aKey | ) |
InitializeUdt
Initializes the user data transfer
const TDesC8 & aKey | : Encryption key of the udt file encrypted with the device public key |
IMPORT_C TInt | IsInCache | ( | const TDesC8 & | aID, |
const TTime & | aTime, | |||
TBool & | aInCache | |||
) |
IsInReplayCache
Checks whether the protected RO identified by aID and aTime has already been added to Replay Cache.
IMPORT_C TInt | IsInCache | ( | const TDesC8 & | aID, |
TBool & | aInCache | |||
) |
IsInReplayCache
Checks whether the protected RO identified by aID has already been added to Replay Cache.
IMPORT_C TInt | SetAuthenticationSeed | ( | const TDesC8 & | aContentId, |
const TDesC8 & | aSeed | |||
) |
IMPORT_C TInt | SetEstimatedArrival | ( | const TDesC8 & | aContentID, |
TTimeIntervalSeconds | aDeltaSeconds | |||
) |
SetEstimatedArrival
Sets the time in which the rights object should arrive
const TDesC8 & aContentID | : content URI |
TTimeIntervalSeconds aDeltaSeconds | : time in seconds to wait for rights |
IMPORT_C TInt | SetName | ( | const TDesC8 & | aContentID, |
const TDesC & | aName | |||
) |
SetName
Associates a human-readable name to given content-ID.
IMPORT_C TInt | StartServer | ( | ) | [static] |
IMPORT_C void | StopWatching | ( | ) | const |
Stop watching the DCF repository server
void | URIFileToArrayL | ( | RFs & | aFs, |
const TDesC & | aFile, | |||
RPointerArray < HBufC8 > & | aList | |||
) | [private] |
RFs & aFs | Open file server session. |
const TDesC & aFile | Input file. |
RPointerArray < HBufC8 > & aList | Output list. |
IMPORT_C TInt | UnwrapMacAndRek | ( | const TDesC8 & | aMacAndRek, |
TKeyTransportScheme | aTransportScheme, | |||
const TDesC8 & | aRightsIssuerId, | |||
const TDesC8 & | aDomainId | |||
) | const |
Unwraps MAC and REK keys that are protected using device public key or domain key. If the keys are wrapped with device public key aDomainId parameter must be set to zero length.
const TDesC8 & aMacAndRek | : Public key protected MAC and REK keys |
TKeyTransportScheme aTransportScheme | |
const TDesC8 & aRightsIssuerId | |
const TDesC8 & aDomainId |
IMPORT_C TInt | VerifyMacL | ( | const TDesC8 & | aSignedInfoElement, |
const TDesC8 & | aMacValue | |||
) | const |
Integrity protection for protected ROs. Calculates HMAC value usign aSignedInfoElement and MAC key. MAC key is unwrapped in AddRecord method. So AddRecord must be called successfully before this method can be called.
RDRMRightsClient & | operator= | ( | const RDRMRightsClient & | ) | [private] |
const RDRMRightsClient & |
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.