Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
b25010d
Add DRM HAL interfaces and data structures
outdooruseonly Mar 9, 2026
3bcc6ac
WIP: work up to now saved before rmoving closer to Android original D…
outdooruseonly Mar 17, 2026
8e83879
WIP: Aligned with Android. Updated import path declarations and licen…
outdooruseonly Mar 18, 2026
8fea656
WIP: Cleaned up and added AVBuffer handles for source and destination…
outdooruseonly Mar 23, 2026
19054b8
WIP: Big documentation update.
outdooruseonly Mar 24, 2026
68e723d
Update drm.md
outdooruseonly Mar 24, 2026
b769785
WIP: Updated drm documentation. Added restrictions around AVBuffer po…
outdooruseonly Mar 25, 2026
558409c
Merge branch '341-taskadd-digital-rights-management-support' of https…
outdooruseonly Mar 25, 2026
73e8286
WIP: Updated drm documentation.
outdooruseonly Mar 26, 2026
4f2bae4
WIP: Updated drm documentation.
outdooruseonly Mar 30, 2026
0fe8069
WIP: Updated drm documentation.
outdooruseonly Mar 31, 2026
612842f
Offline keys under review
outdooruseonly Mar 31, 2026
035195d
WIP: Updated drm documentation and hfp
outdooruseonly Apr 8, 2026
8dd39a1
Update drm/current/com/rdk/hal/drm/DecryptArgs.aidl
outdooruseonly Apr 8, 2026
f7bab99
Update drm/current/com/rdk/hal/drm/DecryptArgs.aidl
outdooruseonly Apr 8, 2026
78d5500
Fix CMakeLists.txt SRC list and copyright headers in DRM AIDL files
Copilot Apr 8, 2026
06f3e5e
Update drm/current/com/rdk/hal/drm/ICryptoPlugin.aidl
outdooruseonly Apr 8, 2026
8215986
Update docs/halif/cdm/current/cdm.md
outdooruseonly Apr 8, 2026
d8b5de3
Update cdm/readme.md
outdooruseonly Apr 8, 2026
4ee998e
Update docs/halif/drm/current/drm.md
outdooruseonly Apr 8, 2026
623e7aa
Update docs/halif/drm/current/drm.md
outdooruseonly Apr 8, 2026
0e5f27d
Update drm/current/com/rdk/hal/drm/IDrmPlugin.aidl
outdooruseonly Apr 8, 2026
e8cfdfa
Fix hfp-drm.yaml indentation and IAVBuffer EX_ILLEGAL_STATUS typos
Copilot Apr 8, 2026
20cf202
Fix maxWidth doc copy/paste error in IVideoDecoder.aidl openWithResol…
Copilot Apr 8, 2026
f5decf8
Fix remaining DRM review feedback: typos, AIDL_BIN block, and paramet…
Copilot Apr 8, 2026
9542c61
Merge branch 'develop' into 341-taskadd-digital-rights-management-sup…
outdooruseonly Apr 8, 2026
e9283c7
Update drm/current/com/rdk/hal/drm/ICryptoPlugin.aidl
outdooruseonly Apr 8, 2026
cfd08f2
Update avbuffer/current/com/rdk/hal/avbuffer/IAVBuffer.aidl
outdooruseonly Apr 8, 2026
a66b2a2
Fix openWithResolution() doc: use backticks for identifiers, decoder …
Copilot Apr 8, 2026
8c5d784
Fix IAVBuffer.aidl audio pool doc: backticks for secureHeap, grammar fix
Copilot Apr 8, 2026
3f81fcb
Update IDrmPlugin.aidl to add a listener
outdooruseonly Apr 8, 2026
6276363
Update drm/current/com/rdk/hal/drm/IDrmFactory.aidl
outdooruseonly Apr 8, 2026
336ce1e
Fix IDrmPlugin.aidl: remove stray trailing backticks in setCipherAlgo…
Copilot Apr 8, 2026
813615f
Update ICryptoPlugin.aidl
outdooruseonly Apr 8, 2026
b224a4e
Update drm/current/com/rdk/hal/drm/ICryptoPlugin.aidl
outdooruseonly Apr 8, 2026
3b27868
Updated NOTICE to explicitly state that Android marerial is used and …
outdooruseonly Apr 9, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions NOTICE
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,22 @@ at build or documentation time. These dependencies are not distributed as part o

---

Uses material from Android which is:
Copyright (C) 2009 The Android Open Source Project
Licensed under the Apache License, Version 2.0


Uses material from Android which is:
Copyright (C) 2021 The Android Open Source Project
Licensed under the Apache License, Version 2.0


Uses material from Android which is:
Copyright (C) 2022 The Android Open Source Project
Licensed under the Apache License, Version 2.0

---

Third-Party Components (Cloned via Script):

1. linux_binder_idl
Expand Down
20 changes: 13 additions & 7 deletions avbuffer/current/com/rdk/hal/avbuffer/IAVBuffer.aidl
Original file line number Diff line number Diff line change
Expand Up @@ -62,20 +62,23 @@ interface IAVBuffer
*
* If the `videoDecoderId` is invalid then the `binder::Status EX_ILLEGAL_ARGUMENT` exception status is returned.
*
* It the platform has exhausted all available memory from the requested heap then the exception status
* If the platform has exhausted all available memory from the requested heap then the exception status
* `binder::Status::Exception::EX_SERVICE_SPECIFIC` with `HALError::OUT_OF_MEMORY` is returned.
*
* If a `secureHeap` is created and the video decoder has not been configured then the exception status
* `binder::Status::Exception::EX_ILLEGAL_STATE` is returned.
*
* @param[in] secureHeap Indicates if the pool is secure.
* @param[in] videoDecoderIndex The index of the video decoder resource.
* @param[in] listener Listener for space available callbacks.
*
* @returns A new `Pool` object with a valid handle.
*
* @exception binder::Status::Exception::EX_NONE for success
* @exception binder::Status::Exception::EX_ILLEGAL_ARGUMENT if videoDecoderIndex is invalid
* @exception binder::Status::Exception::EX_SERVICE_SPECIFIC, HALError::OUT_OF_MEMORY if heap is exhausted
* @exception binder::Status::Exception::EX_ILLEGAL_ARGUMENT if videoDecoderIndex is invalid
* @exception binder::Status::Exception::EX_SERVICE_SPECIFIC, HALError::OUT_OF_MEMORY if heap is exhausted
* @exception binder::Status::Exception::EX_ILLEGAL_STATE decoder not configured
*
*
* @pre The IVideoDecoder.Id must have been obtained from IVideoDecoderManager.getVideoDecoderIds()
*
* @see destroyPool()
Expand All @@ -88,9 +91,12 @@ interface IAVBuffer
* If the audio pool is for audio data not destinated for a vendor audio decoder
* (e.g. system audio PCM) then the ID must be IAudioDecoder.Id.UNDEFINED.
*
* It the platform has exhausted all available memory from the requested heap then the exception status
* If the platform has exhausted all available memory from the requested heap then the exception status
* `binder::Status::Exception::EX_SERVICE_SPECIFIC` with `HALError::OUT_OF_MEMORY` is returned.
*
* If a `secureHeap` is created and the audio decoder has not been configured then the exception status
* `binder::Status::Exception::EX_ILLEGAL_STATE` is returned.
*
* If the `audioDecoderId` is invalid then the `binder::Status EX_ILLEGAL_ARGUMENT` exception status is returned.
*
* @param[in] secureHeap Indicates if the pool is secure.
Expand All @@ -101,8 +107,8 @@ interface IAVBuffer
*
* @exception binder::Status::Exception::EX_NONE for success
* @exception binder::Status::Exception::EX_ILLEGAL_ARGUMENT if audioDecoderId is invalid
* @exception binder::Status::Exception::EX_SERVICE_SPECIFIC, HALError::OUT_OF_MEMORY if heap is exhausted
*
* @exception binder::Status::Exception::EX_SERVICE_SPECIFIC, HALError::OUT_OF_MEMORY if heap is exhausted
* @exception binder::Status::Exception::EX_ILLEGAL_STATE decoder not configured
*
* @pre The IAudioDecoder.Id must have been obtained from IAudioDecoderManager.getAudioDecoderIds()
* or IAudioDecoder.Id.UNDEFINED must be used.
Expand Down
1 change: 1 addition & 0 deletions cdm/readme.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# Content Decryption Module Support

Deprecated. See DRM
2 changes: 2 additions & 0 deletions docs/halif/cdm/current/cdm.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# CDM

CDM is deprecated. Please see ../drm and https://github.com/rdkcentral/rdk-halif-aidl/tree/main/drm/current

## References

!!! info References
Expand Down
305 changes: 305 additions & 0 deletions docs/halif/drm/current/drm.md

Large diffs are not rendered by default.

85 changes: 85 additions & 0 deletions drm/current/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
#** *****************************************************************************
# *
# * If not stated otherwise in this file or this component's LICENSE file the
# * following copyright and licenses apply:
# *
# * Copyright 2025 RDK Management
# *
# * Licensed under the Apache License, Version 2.0 (the "License");
# * you may not use this file except in compliance with the License.
# * You may obtain a copy of the License at
# *
# *
# * http://www.apache.org/licenses/LICENSE-2.0
# *
# * Unless required by applicable law or agreed to in writing, software
# * distributed under the License is distributed on an "AS IS" BASIS,
# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# * See the License for the specific language governing permissions and
# * limitations under the License.
# *
#** ******************************************************************************
cmake_minimum_required(VERSION 3.8)

project(Drm
LANGUAGES NONE
VERSION 1.0)

if (NOT COMMAND compile_aidl)
message(FATAL_ERROR "Do not invoke module level CMake directly!\nInvoke CMake at root level instead!")
endif()

set(SRC_DIR com/rdk/hal/drm)

set(SRC
${SRC_DIR}/CryptoSchemes.aidl
${SRC_DIR}/DecryptArgs.aidl
${SRC_DIR}/DrmErrors.aidl
${SRC_DIR}/DrmMetric.aidl
${SRC_DIR}/DrmMetricGroup.aidl
${SRC_DIR}/DrmMetricNamedValue.aidl
${SRC_DIR}/DrmMetricValue.aidl
${SRC_DIR}/EventType.aidl
${SRC_DIR}/HdcpLevel.aidl
${SRC_DIR}/HdcpLevels.aidl
${SRC_DIR}/ICryptoPlugin.aidl
${SRC_DIR}/IDrmFactory.aidl
${SRC_DIR}/IDrmPlugin.aidl
${SRC_DIR}/IDrmPluginListener.aidl
${SRC_DIR}/KeyRequest.aidl
${SRC_DIR}/KeyRequestType.aidl
${SRC_DIR}/KeySetId.aidl
${SRC_DIR}/KeyStatus.aidl
${SRC_DIR}/KeyStatusType.aidl
${SRC_DIR}/KeyType.aidl
${SRC_DIR}/KeyValue.aidl
${SRC_DIR}/Mode.aidl
${SRC_DIR}/NumberOfSessions.aidl
${SRC_DIR}/Pattern.aidl
${SRC_DIR}/ProvideProvisionResponseResult.aidl
${SRC_DIR}/ProvisionRequest.aidl
${SRC_DIR}/SecurityLevel.aidl
${SRC_DIR}/Status.aidl
${SRC_DIR}/SubSample.aidl
${SRC_DIR}/SupportedContentType.aidl
${SRC_DIR}/Uuid.aidl
)

set(INCLUDE_DIRECTORY
.
)

set(COMPILE_AIDL_ARGV "")

if (DEFINED AIDL_GEN_DIR)
list(APPEND COMPILE_AIDL_ARGV TARGET_DIRECTORY ${AIDL_GEN_DIR})
endif()

if (DEFINED AIDL_BIN)
list(APPEND COMPILE_AIDL_ARGV AIDL_BIN ${AIDL_BIN})
endif()

compile_aidl(${SRC}
INCLUDE_DIRECTORY ${INCLUDE_DIRECTORY}
${COMPILE_AIDL_ARGV}
)
48 changes: 48 additions & 0 deletions drm/current/com/rdk/hal/drm/CryptoSchemes.aidl
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
/*
* If not stated otherwise in this file or this component's LICENSE file the
* following copyright and licenses apply:
*
* Copyright 2025 RDK Management
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* -------------------------------------------------------------------
* This file is derived from Android 16 drm interface definitions:
*
* https://android.googlesource.com/platform/hardware/interfaces/+/refs/tags/android-16.0.0_r4/drm/aidl/android/hardware/drm
*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0.
* -------------------------------------------------------------------
*/

package com.rdk.hal.drm;

import com.rdk.hal.drm.SupportedContentType;
import com.rdk.hal.drm.Uuid;

@VintfStability
parcelable CryptoSchemes {

/**
* Supported crypto schemes
*/
List<Uuid> uuids;

/**
* Supported mime types, and supported SecurityLevels for each mime
*/
List<SupportedContentType> mimeTypes;

}
94 changes: 94 additions & 0 deletions drm/current/com/rdk/hal/drm/DecryptArgs.aidl
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
/*
* If not stated otherwise in this file or this component's LICENSE file the
* following copyright and licenses apply:
*
* Copyright 2025 RDK Management
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* -------------------------------------------------------------------
* This file is derived from Android 16 drm interface definitions:
*
* https://android.googlesource.com/platform/hardware/interfaces/+/refs/tags/android-16.0.0_r4/drm/aidl/android/hardware/drm
*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0.
* -------------------------------------------------------------------
*/
package com.rdk.hal.drm;

import com.rdk.hal.drm.KeyStatusType;
import com.rdk.hal.drm.Mode;
import com.rdk.hal.drm.Pattern;
import com.rdk.hal.drm.SubSample;

/**

Check failure on line 36 in drm/current/com/rdk/hal/drm/DecryptArgs.aidl

View workflow job for this annotation

GitHub Actions / call-fossid-workflow / Fossid Annotate PR

FossID Detected License Issue

Snippet with 'Apache-2.0' file license found (47 lines) Location: drm/aidl/android/hardware/drm/DecryptArgs.aidl (link unavailable) Component: platform/platform/hardware/interfaces@android-u-beta-1-gpl Download: https://android.googlesource.com/platform/hardware/interfaces/+archive/refs/tags/android-u-beta-1-gpl.tar.gz
* Arguments to ICryptoPlugin decrypt
*/
@VintfStability
parcelable DecryptArgs {

/**
* A flag to indicate if a secure decoder is being used.
*
* This enables the plugin to configure buffer modes to work consistently
* with a secure decoder.
*
*/
boolean secure;

/**
* The keyId for the key that is used to do the decryption.
*
* The keyId refers to a key in the associated MediaDrm instance.
*/
byte[] keyId;

/**
* The initialization vector
*/
byte[] iv;

/**
* Crypto mode
*/
Mode mode;

/**
* Crypto pattern
*/
Pattern pattern;

/**
* A vector of subsamples indicating the number of clear and encrypted
* bytes to process.
*
* This allows the decrypt call to operate on a range of subsamples in a
* single call
*/
SubSample[] subSamples;

/**
* Input AVBuffer handle for the encrypted data.
*
* It is the responsibility of the caller to recycle/free the allocated AVBuffer after the call to decrypt returns.
*/
long sourceBufferHandle;

/**
* Output AVBuffer handle for the decrypted data.
*/
long destinationBufferHandle;

}
Loading
Loading