| View previous topic :: View next topic |
| Author |
Message |
Blu-Ray
Joined: 28 Nov 2009 Posts: 3
|
Posted: Sat Nov 28, 2009 9:54 pm Post subject: Adding mountpoints from webinterface? |
|
|
Hello,
is there any possibility to dynamically add and delete mountpoints from webinterface and not by using the config-file? Would be really useful.
Thanks!
________
Washington medical marijuana
Last edited by Blu-Ray on Wed Feb 16, 2011 10:15 am; edited 1 time in total |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sun Nov 29, 2009 10:42 pm Post subject: |
|
|
such a feature is not in place although conceptually something could be added for that. The issue is that it would be only temporary, an icecast restart or reread of the xml would mean it goes. Are you thinking of anything in particular or are you wanting all mount tags settable via url?
karl. |
|
| Back to top |
|
 |
Blu-Ray
Joined: 28 Nov 2009 Posts: 3
|
Posted: Mon Nov 30, 2009 5:39 pm Post subject: |
|
|
I just thought that it would be good, especially for a big webradio station if they could add and delete mountpoints and source users from the webpanel without having to restart the whole server software or getting access to the server via SSH.
Maybe an sqlite database extension or something else could be added to save those settings
________
How to love
Last edited by Blu-Ray on Wed Feb 16, 2011 10:15 am; edited 1 time in total |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Mon Nov 30, 2009 6:18 pm Post subject: |
|
|
From the description in the first paragraph, it sounds like a wildcard mount with the stream auth url option would be of interest to you? In the trunk code the stream auth optiin is available but wildcard mountpoints are not, both are in the kh tree though.
karl. |
|
| Back to top |
|
 |
Blu-Ray
Joined: 28 Nov 2009 Posts: 3
|
Posted: Mon Nov 30, 2009 7:31 pm Post subject: |
|
|
Sorry for my English expression, I am from Germany.
I?m looking for an option in the icecast webpanel to dynamically add and delete mountpoints, change passwords of source-users (those who stream audio to the server) and so on. Just stuff you can currently only do in the config.xml file. That would avoid disconnecting all listeners if you have to restart the whole server software to load modifications in config file you did.
In my case I often have to change passwords of source users for mountpoints and I always have to restart the server software and all users disconnect from server.
________
HASH
Last edited by Blu-Ray on Wed Feb 16, 2011 10:15 am; edited 1 time in total |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Mon Nov 30, 2009 10:02 pm Post subject: |
|
|
in trunk/kh you can use the authentication option stream_auth like you do for listener_add to pass that authentication off to an external script (eg php) you can then use whatever mechanism you see fit to allow or deny a connecting source client.
BTW a HUP signal will reload the xml without dropping any clients, even in 2.3.2
karl. |
|
| Back to top |
|
 |
bbk

Joined: 15 Oct 2005 Posts: 79
|
Posted: Sat Dec 05, 2009 11:41 pm Post subject: |
|
|
i hope it is planed to upstream this into the release branch as well.
the concept i have in one project is that users on our webstation can connect themself to make a live transmission. so it whould be nice to give the users a personal password.
as i understand it in the kh branch it is possible to change the password, with a authentification modul. do i understand this right that i just have to write a php script returning true (or something) when the authentification was successful? then i whould be able to use whatever login process like ldap ... then it possible to have many passwords for one mountpoint at the same time?
yours, _________________ ::bbk::
http://audioasyl.net |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sun Dec 06, 2009 1:04 am Post subject: |
|
|
yes that is how it is supposed to work. The only additional concern that the php would have to deal with is that admin requests using source authentication will also trigger the script, for those &admin=1 is provided. Think mp3 metadata updates from the source client.
This mechanism is already merged into the trunk codebase.
karl. |
|
| Back to top |
|
 |
Felix Ding
Joined: 18 Dec 2009 Posts: 3 Location: Shanghai, China
|
Posted: Fri Dec 18, 2009 3:36 am Post subject: |
|
|
Hello there, I'm also looking for a similar solution. The website I'm designing allows users to register (with a username and a password) and to start a new radio station. The user's username (which is unique) would be used as a new mount point. So that after the registration, the user can use his/her favourite DJ software to feed Icecast instantly.
Is it possible on Icecast? Should I use 2.3.2 or the latest trunk branch? And, how do I suppose to do that, any hints or documents?
Thanks. |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Fri Dec 18, 2009 4:16 am Post subject: |
|
|
The stream_auth code can be used for that sort of thing but that is only available in the trunk and kh codebases, it is not in the 2.3.2 release.
The only difference in usage between kh and trunk with regard to source client authentication via auth url is for shoutcast style source clients. This is because shoutcast style source auth send the password and then expects a reply before sending more headers. The trick I've done in kh is to say yes initially and then drop the connection if auth fails. Something similar can be done in trunk.
karl. |
|
| Back to top |
|
 |
Felix Ding
Joined: 18 Dec 2009 Posts: 3 Location: Shanghai, China
|
Posted: Fri Dec 18, 2009 9:59 am Post subject: |
|
|
Thanks for the quick reply!
What I need is not only authentication, but also adding/removing mount points dynamically.
I have read some documents and searched a lot, it seems that we have 2 methods to do that:
1. Adding/removing mount points definitions in icecast.xml, then use/kill the HUP signal or use 'icecast reload' under shell to force Icecast to reload icecast.xml,
2. Use 'icecast_auth' PHP scripts in 'examples' directory. I noticed that there is a 'mount add' feature in the script. And in the mount section in icecast.xml, use the code below:
| Code: |
<mount>
<mount-name>/auth_example.ogg</mount-name>
<authentication type="url">
<option name="mount_add" value="http://myauthserver.net/notify_mount.php"/>
<option name="mount_remove" value="http://myauthserver.net/notify_mount.php"/>
<option name="listener_add" value="http://myauthserver.net/notify_listener.php"/>
<option name="listener_remove" value="http://myauthserver.net/notify_listener.php"/>
</authentication>
</mount> |
Are the ideas right? |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Fri Dec 18, 2009 10:03 pm Post subject: |
|
|
If you want to explicitly want to add a mount block then it's a change to the xml then a reload via HUP (or admin call in kh). The question that needs to be cleared up is would a wildcard mount be suitable in your situation. eg
<mount>
<mount-name>/*.ogg</mount-name>
....
</mount>
In which case no reload would be required because those mount settings would apply for all streams (or files in the case of auth).
karl. |
|
| Back to top |
|
 |
|