libdvdcss error: drive would not authenticate

For questions and discussion that is NOT (I repeat NOT) specific to a certain Operating System.
inglorion
New Cone
New Cone
Posts: 5
Joined: 28 May 2005 22:01
Contact:

libdvdcss error: drive would not authenticate

Postby inglorion » 28 May 2005 22:31

I just bought an AOpen DUW1608/ARR DVD writer, but I'm unable to play encrypted DVDs with it. I get these messages (with DVDCSS_VERBOSE=2):

libdvdread: Using libdvdcss version 1.2.5 for DVD access
libdvdcss debug: opening target `/dev/cdrom'
libdvdcss debug: using libc for access
libdvdcss debug: disc is scrambled
libdvdcss debug: requesting AGID
libdvdcss error: drive would not authenticate

All this is on a Debian (sid) system. The drive is connected to a VIA EPIA SP8000E motherboard. The whole system is brand new. The DVDs play using VLC on Mac OS X.

Using the utility regionset, I found that the drive's region mask was set to 0xFF (which, if I interpret it correctly, means that no regions are allowed). I set the region mask to 0XFD (region 2, just like the DVDs I'm trying to play), but that didn't change anything. 4 changes left...

From the libdvdcss documentation, I get the impression that DVD CSS decryption should be possible without help from the drive (seeing that it can be done even without a DVD drive). I tried playing around with the DVDCSS_METHOD setting, but to no avail. The errors stay the same.

Where do I go from here? I've already asked the vendor if this could mean the drive is broken, but I honestly don't think so; it plays unscrambled DVDs and other media fine.

The DJ
Cone Master
Cone Master
Posts: 5987
Joined: 22 Nov 2003 21:52
VLC version: git
Operating System: Mac OS X
Location: Enschede, Holland
Contact:

Postby The DJ » 30 May 2005 14:45

the descrambler asks the drive's driver for the AGID. The driver does not return this. So it's probably an issue with the linux kernel driver or something.
Don't use PMs for support questions.

inglorion
New Cone
New Cone
Posts: 5
Joined: 28 May 2005 22:01
Contact:

cannot get AGID

Postby inglorion » 30 May 2005 17:22

Thanks for your reply. This is what I figured. What I don't get, though, is why libdvdcss needs the AGID. According to the documentation, the decryption can be done even without a DVD drive (using the "title" method). So how come it doesn't work for me? I set the DVDCSS variable, but it seems to have no effect.

On a side note: I saw you're in Enschede; I am in Hengelo. Maybe we can meet up someday?

inglorion
New Cone
New Cone
Posts: 5
Joined: 28 May 2005 22:01
Contact:

Fixed

Postby inglorion » 30 May 2005 17:27

Ok, I figured out what the problem is. As soon as libdvdcss finds out the DVD is scrambled, it tries to get the disc key, and gives up if that doesn't work (apparently regardless of the DVDCSS_METHOD setting).

The patch below fixes that, and I can now watch both scrambled and unscrambled DVDs.

Code: Select all

diff -Naur libdvdcss-1.2.8.orig/src/libdvdcss.c libdvdcss-1.2.8/src/libdvdcss.c --- libdvdcss-1.2.8.orig/src/libdvdcss.c Sun Jun 22 16:08:53 2003 +++ libdvdcss-1.2.8/src/libdvdcss.c Mon May 30 17:17:59 2005 @@ -362,14 +362,6 @@ if( dvdcss->b_scrambled && dvdcss->b_ioctls ) { i_ret = _dvdcss_disckey( dvdcss ); - - if( i_ret < 0 ) - { - _dvdcss_close( dvdcss ); - free( dvdcss->psz_device ); - free( dvdcss ); - return NULL; - } } /* If the cache is enabled, extract a unique disc ID */
Please excuse the double post. I must have accidentally hit "Submit" before clicking "Preview".
Last edited by inglorion on 30 May 2005 17:29, edited 1 time in total.

inglorion
New Cone
New Cone
Posts: 5
Joined: 28 May 2005 22:01
Contact:

Fixed

Postby inglorion » 30 May 2005 17:27

Ok, I figured out what the problem is. As soon as libdvdcss finds out the DVD is scrambled, it tries to get the disc key, and gives up if that doesn't work (apparently regardless of the DVDCSS_METHOD setting).

The patch below fixes that, and I can now watch both scrambled and unscrambled DVDs.

Code: Select all

diff -Naur libdvdcss-1.2.8.orig/src/libdvdcss.c libdvdcss-1.2.8/src/libdvdcss.c --- libdvdcss-1.2.8.orig/src/libdvdcss.c Sun Jun 22 16:08:53 2003 +++ libdvdcss-1.2.8/src/libdvdcss.c Mon May 30 17:17:59 2005 @@ -362,14 +362,6 @@ if( dvdcss->b_scrambled && dvdcss->b_ioctls ) { i_ret = _dvdcss_disckey( dvdcss ); - - if( i_ret < 0 ) - { - _dvdcss_close( dvdcss ); - free( dvdcss->psz_device ); - free( dvdcss ); - return NULL; - } } /* If the cache is enabled, extract a unique disc ID */

Sam Hocevar
New Cone
New Cone
Posts: 6
Joined: 20 Aug 2004 09:47

Postby Sam Hocevar » 01 Jun 2005 13:46

This patch is definitely too high level and will leave the drive in a very
bad state if a real error occurs. Could you please have a deeper look
inside the _dvdcss_disckey() function and try to see which error causes
the return value to be negative in your case, instead?

inglorion
New Cone
New Cone
Posts: 5
Joined: 28 May 2005 22:01
Contact:

Postby inglorion » 01 Jun 2005 16:15

I know what causes the problem. After obtaining the AGID, the library is unable to determine which authentication variant was used (all 32 fail). By the way, from the debug messages, it appears that getting the AGID fails. I've added a message "Got AGID" to my version to eliminate that confusion.

I don't know what causes none of the 32 variants to match. All I know is that, in my opinion, the library shouldn't fail after the disc method fails, especially if another method is requested through the enviroment variable. My patch accomplishes that and no more; sorry if that isn't good enough. I have no knowledge whatsoever about DVD drive programming. However, if I can help with testing I gladly will.


Return to “General VLC media player Troubleshooting”

Who is online

Users browsing this forum: No registered users and 31 guests