Contents |
DRM License Checker API allows usage rights enforcement for native applications. It consists of functions for checking usage rights.
Clients of the DRM License Checker API are protected applications.
API category | public |
API type | c++ |
Existed since | Legacy S60 2.6 |
API libraries | DRMLicenseChecker.lib |
Location | /sf/mw/drm/drm_pub/drm_license_checker_api
|
Buildfiles | /sf/mw/drm/drm_pub/drm_license_checker_api/group/bld.inf
|
The DRM License Checker API is intended for application protection. It provides a single method with which the application can check if its license is valid or not. It can be categorized as a library API and its type is a method call interface.
This API is fully supported in the WINS/WINSCW emulator environment.
DRM License Checker API is an SDK API and available from S60 release 2.6 onwards.
The only use case for DRM License Checker API is to check if the license of the application is valid or not. This is done by decrypting a critical data file and if the decryption is successful, the license is valid.
Classes | Files |
---|---|
|
/epoc32/include/mw/DRMLicenseChecker.h
The following class diagram shows the DRM License Checker API.
The DRM License checker API enables a client application check for the existence of the necessary rights. It allows decryption of the installed data files to be used further during runtime.
The CheckLicense
method is used to check if the license
is valid for an application. This function performs a license check by decrypting a data file
and returning the decrypted contents of the data file. A license check can
only succeed if the Rights object associated with the calling application
exists and sufficient rights are present. If the license check fails, an error
is returned.
The decrypted data is used by the calling application in a non-trivial
way to further increase security. A simple check whether the CheckLicense
method
completed successfully is not enough. Ideally, the contents of the data file
are a crucial element of the calling application, such as, artwork or control
data for the application execution.
The following code example elaborates the usage of the DRM License Checker API:
CDRMLicenseChecker* licenseChecker; ... if ( licenseChecker->CheckLicense( dataFile, data ) == KErrNone ) { InitializeGame(data); delete data; } else { // cause severe error } ...
All the functions use return values as error code indicators. In addition,
the leave mechanism of the Symbian platform is used. Errors are indicated by values
other than KErrNone
. All leave situations are fatal. If a
function leaves, the interface object needs to be deallocated. Recovery
is not possible.
The DRM License Checker API does not consume memory significantly other than for creating the required objects.
No extensions are possible to the DRM License Checker API.
The basic functionality of this API cannot be limited.