[Icecast] Adding authenticated mountpoints

Karl Heyes karl at xiph.org
Tue Apr 12 11:31:48 UTC 2005


On Tue, 2005-04-12 at 12:02, James McCurrach wrote:
> OK, so let me check I understand how the timing must work:
> 
> 0)  New user joins the jukebox and wants to start listening to music. 
> Jukebox app selects a mountpoint name, user ID and password
> 1)  Modify the icecast.conf file with the new mountpoint
> 2)  Send HUP to icecast
> 3)  Set up username:password for new stream
> 4)  Create new stream's ices.conf file
> 5)  Spawn new instance of ices to stream the music
> 6)  Invite listener to start listening (tell him his userid, password,
> point him to url) ...

looks about right.

> When I send a HUP to icecast will it disrupt the listening experience of
> the other listening users on other streams?

no, the HUP causes the xml config to be re-read and sets some triggers
in various parts for rechecking, but doesn't affecting existing streams,
unless it's a relay that has been removed.

> I'm not too keen on doing the password management via the admin
> interface as I really want this process to be automated and my php/xml
> isn't (yet) up to a dialogue with an external application - so maybe
> the auth by url is better.

The use of curl/wget or similar can help there, that isn't a big issue
eg curl http://admin:hackme@host:8000/admin/.......?..&...&', the
problem with modifying the file yourself is a question of locking so
that multiple updates don't occur at the same time.

I haven't done the documentation for auth url yet but I've listed the
auth options at the top of the auth_url.c file, essentially

for source stream connection
            <option name="start"    value="http://mysite.com/stream-start.php"/>
            <option name="end"      value="http://mysite.com/stream-end.php"/>

for connecting user
            <option name="add"      value="http://mysite.com/add-ok.php"/>

for disconnecting user
            <option name="remove"   value="http://mysite.com/remove-user.php"/>

header returned if user is authenticated. default is "icecast-auth-user: 1"
            <option name="header"   value="HTTP/1.1 200 OK"/>


My current work is on 
http://mediacast1.com/~karl/testing/icecast-2.2-kh3pre.tar.gz

karl.





More information about the Icecast mailing list