Including credentials in an M3U8 file for VLC using RTSP

For questions and discussion that is NOT (I repeat NOT) specific to a certain Operating System.
calande
Blank Cone
Blank Cone
Posts: 88
Joined: 17 Feb 2010 13:53
Operating System: W10
Location: Coneville

Including credentials in an M3U8 file for VLC using RTSP

Postby calande » 01 Feb 2025 20:32

Hello,

I'm creating an M3U8 file containing RTSP streams of my IP cameras. Their accesses are restricted with credentials. I can successfully access them using VLC manually, opening a network stream (a popup asks for my username and password, and then I can see my live video). The problem is when I open an M3U8 file that has the stream and the credentials. VLC still asks for the password. This is my M3U8 file:

Code: Select all

#EXTM3U #EXTVLCOPT:network-caching=1000 #EXTVLCOPT:rtsp-user=myusernamegoeshere #EXTVLCOPT:rtsp-pwd=mypasswordgoeshere rtsp://192.168.1.10:554
I tried changing the stream URL to

Code: Select all

rtsp://myusernamegoeshere:mypasswordgoeshere@192.168.1.10:554
and also to

Code: Select all

http://myusernamegoeshere:mypasswordgoeshere@192.168.1.10:554
...to no avail... Do you know how to store the password in my M3U8 file so that VLC doesn't keep asking for it?

Thank you.

calande
Blank Cone
Blank Cone
Posts: 88
Joined: 17 Feb 2010 13:53
Operating System: W10
Location: Coneville

Re: Including credentials in an M3U8 file for VLC using RTSP

Postby calande » 05 Feb 2025 14:09

Does anyone know?

JanB1
New Cone
New Cone
Posts: 1
Joined: 19 Feb 2025 08:05

Re: Including credentials in an M3U8 file for VLC using RTSP

Postby JanB1 » 19 Feb 2025 08:11

Interestingly enough, I also currently have problems when trying to connect to an RTSP stream and providing the username and password in the URL.
When I try to connect to the stream using "rtsp://myusernamegoeshere:mypasswordgoeshere@192.168.1.10" for example, in the debug output I get the info that "live555 error: Failed to connect with rtsp://myusernamegoeshere:554" and then "access_realrtsp error: cannot connect to myusernamegoeshere:0".

In the Log I can clearly see that VLC Player tries to connect to the wrong host. Maybe this problem is related to yours?


Return to “General VLC media player Troubleshooting”

Who is online

Users browsing this forum: No registered users and 40 guests