Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Jean-Baptiste Kempf
libaacs
Commits
d92b2485
Commit
d92b2485
authored
Feb 05, 2016
by
npzacs
Browse files
aacs_get_disc_id(): check for empty id
parent
2658af65
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/libaacs/aacs.c
View file @
d92b2485
...
...
@@ -92,8 +92,9 @@ struct aacs {
uint8_t
device_binding_id
[
16
];
};
static
const
uint8_t
empty_key
[
16
]
=
{
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
};
static
const
uint8_t
empty_key
[
20
]
=
{
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
};
static
const
uint8_t
aacs_iv
[
16
]
=
{
0x0b
,
0xa0
,
0xf8
,
0xdd
,
0xfe
,
0xa6
,
0x1f
,
0xb3
,
0xd8
,
0xdf
,
0x9f
,
0x56
,
0x6a
,
0x05
,
0x0f
,
0x78
};
...
...
@@ -1288,7 +1289,11 @@ int aacs_get_mkb_version(AACS *aacs)
const
uint8_t
*
aacs_get_disc_id
(
AACS
*
aacs
)
{
return
aacs
->
disc_id
;
if
(
memcmp
(
aacs
->
disc_id
,
empty_key
,
sizeof
(
aacs
->
disc_id
)))
{
return
aacs
->
disc_id
;
}
return
NULL
;
}
const
uint8_t
*
aacs_get_content_cert_id
(
AACS
*
aacs
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment