1 /*****************************************************************************
2 * dvd_css.h: Structures for DVD authentification and unscrambling
3 *****************************************************************************
4 * Copyright (C) 1999-2001 VideoLAN
6 * Author: Stéphane Borel <stef@via.ecp.fr>
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
21 *****************************************************************************/
22 #if defined( HAVE_SYS_DVDIO_H ) || defined( LINUX_DVD )
25 typedef u8 DVD_key_t[KEY_SIZE];
29 u8 pi_challenge[2*KEY_SIZE];
32 u8 pi_key_check[KEY_SIZE];
36 typedef struct title_key_s
38 u32 i; /* This signification of this parameter
39 depends on the function it is called from :
40 *from DVDInit -> i == i_lba
41 *from CSSGetKeys -> i == i_occ */
53 title_key_t* p_title_key;
56 /*****************************************************************************
57 * Prototypes in dvd_css.c
58 *****************************************************************************/
59 struct css_s CSSInit ( int );
60 int CSSGetKeys ( struct css_s* );
61 int CSSDescrambleSector( DVD_key_t , u8* );