1 /* 2 * Copyright (C) 2014 Intel Corporation. All rights reserved. 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 #ifndef __WV_MOD_DRM_ERROR_H_ 18 #define __WV_MOD_DRM_ERROR_H_ 19 20 // Error codes for the modular Widevine DRM library. 21 enum drm_wv_mod_result 22 { 23 DRM_WV_MOD_SUCCESS, 24 DRM_WV_MOD_ERROR_INIT_FAILED = 0x60000001, 25 DRM_WV_MOD_ERROR_TERMINATE_FAILED, 26 DRM_WV_MOD_ERROR_SHORT_BUFFER, 27 DRM_WV_MOD_ERROR_NO_DEVICE_KEY, 28 DRM_WV_MOD_ERROR_KEYBOX_INVALID, 29 DRM_WV_MOD_ERROR_NO_KEYDATA, 30 DRM_WV_MOD_ERROR_DECRYPT_FAILED, 31 DRM_WV_MOD_ERROR_WRITE_KEYBOX, 32 DRM_WV_MOD_ERROR_WRAP_KEYBOX, 33 DRM_WV_MOD_ERROR_BAD_MAGIC, 34 DRM_WV_MOD_ERROR_BAD_CRC, 35 DRM_WV_MOD_ERROR_NO_DEVICEID, 36 DRM_WV_MOD_ERROR_RNG_FAILED, 37 DRM_WV_MOD_ERROR_RNG_NOT_SUPPORTED, 38 DRM_WV_MOD_ERROR_OPEN_SESSION_FAILED, 39 DRM_WV_MOD_ERROR_CLOSE_SESSION_FAILED, // 0x10 40 DRM_WV_MOD_ERROR_INVALID_SESSION, 41 DRM_WV_MOD_ERROR_NOT_IMPLEMENTED, 42 DRM_WV_MOD_ERROR_NO_CONTENT_KEY, 43 DRM_WV_MOD_ERROR_CONTROL_INVALID, 44 DRM_WV_MOD_ERROR_INVALID_CONTEXT, 45 DRM_WV_MOD_ERROR_SIGNATURE_FAILURE, 46 DRM_WV_MOD_ERROR_DEVICE_NOT_RSA_PROVISIONED, 47 DRM_WV_MOD_ERROR_INVALID_RSA_KEY, 48 DRM_WV_MOD_ERROR_INVALID_NONCE, 49 DRM_WV_MOD_ERROR_KEY_EXPIRED, 50 DRM_WV_MOD_ERROR_TOO_MANY_SESSIONS, 51 DRM_WV_MOD_ERROR_TOO_MANY_KEYS, 52 DRM_WV_MOD_ERROR_INSUFFICIENT_RESOURCES, 53 DRM_WV_MOD_ERROR_INSUFFICIENT_HDCP, 54 DRM_WV_MOD_ERROR_UNKNOWN_FAILURE, 55 DRM_WV_MOD_ERROR_UNSUPPORTED, // 0x20 56 DRM_WV_MOD_ERROR_ILLEGAL_PARAMETER, 57 DRM_WV_MOD_ERROR_SEP_DRIVER_OPERATION_FAILED, 58 DRM_WV_MOD_ENCRYPTION_DECRYPTION_SIZE_INCORRECT, 59 DRM_WV_MOD_ERROR_BUFFER_TOO_SMALL, 60 DRM_WV_MOD_ERROR_BUFFER_TYPE_INVALID, 61 DRM_WV_MOD_ERROR_DATA_SIZE_TOO_LARGE, 62 DRM_WV_MOD_ERROR_RETURN_BUFFER_TOO_SMALL, 63 DRM_WV_MOD_ERROR_DMA_DATA_SIZE_TOO_LARGE, 64 DRM_WV_MOD_ERROR_NONCE_GENERATION_FAILURE, 65 DRM_WV_MOD_ERROR_SESSION_NALU_PARSE_FAILURE, 66 DRM_WV_MOD_ERROR_CRYPTO_OP_FAILURE, 67 DRM_WV_MOD_ERROR_DERIVED_ENCRYPTION_KEY_FAILED, 68 DRM_WV_MOD_ERROR_DERIVED_CLIENT_MAC_KEY_FAILED, 69 DRM_WV_MOD_ERROR_DERIVED_SERVER_MAC_KEY_FAILED, 70 DRM_WV_MOD_ERROR_KEY_DERIVATION_FAILED, 71 DRM_WV_MOD_ERROR_INVALID_DATA_FORMAT_VERSION, 72 DRM_WV_MOD_ERROR_INVALID_PLAYBACK_STATE, 73 DRM_WV_MOD_ERROR_INVALID_SESSION_STATE, 74 DRM_WV_MOD_ERROR_INVALID_USAGE_TABLE_GENERATION_NUM, 75 DRM_WV_MOD_ERROR_INVALID_USAGE_TABLE_MAGIC 76 }; 77 78 #endif 79