Icecast Streaming Media Server Forum Index Icecast Streaming Media Server
Icecast is a Xiph Foundation Project
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Kill source via php-Script

 
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server
View previous topic :: View next topic  
Author Message
kai4711



Joined: 21 Nov 2007
Posts: 30

PostPosted: Wed Dec 12, 2007 8:18 pm    Post subject: Kill source via php-Script Reply with quote

Hi Guys,

I tried to modify a shoutcast-kick-source script to work with icecast but it doesnt realy work...

Does anyone have some ideas?

Code:
<?php
function kick($host,$port,$mount,$username,$password) {
    $fp=@fsockopen($host,$port,&$errno,&$errstr,10);
    if (!$fp) {$success = false;}
    else {     
       fputs($fp,"GET /admin/killsource.xsl?mount=/$mount HTTP/1.1");
        fputs($fp,"User-Agent:KaiZilla");
        fputs($fp,"Host: $host");
        fputs($fp,"Authorization: Basic ".base64_encode($username.":".$password)."rnrn");
        fputs($fp,"");
      fclose($fp);
        $success = true;
   }
   return $success;
}
?>

It echoes true but the source is still connected to the server...

Thank you in advance,
Kai
Back to top
View user's profile Send private message
karlH
Code Warrior
Code Warrior


Joined: 13 Jun 2005
Posts: 4503
Location: UK

PostPosted: Wed Dec 12, 2007 10:40 pm    Post subject: Reply with quote

what does the error log report when it receives the killsource request

karl.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
kai4711



Joined: 21 Nov 2007
Posts: 30

PostPosted: Sat Jan 19, 2008 7:01 pm    Post subject: Reply with quote

Hey!

Curiously there is no log to the error-log but no log in the access log too..

When i point manually to the killsource.xsl there is a entry in access.log ...

Kai
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group
subRebel style by ktauber