What about scrapping the access logs for connections that have completed, or utilizing netstat outputs to get active listeners (minus sources)? Either of those options would get you remote IP addresses, both a slightly different view in that logs are after a connection closes, while netstat is while the connection is open. -----Original Message----- From: Icecast-dev <icecast-dev-bounces at xiph.org> On Behalf Of Reaz Baksh Sent: Monday, September 21, 2020 3:03 PM To: icecast-dev at xiph.org Subject: Re: [Icecast-dev] Listener stats Hello Jordan Thanks for the reply. I commented out all the fields in the status-json.xsl but it didn't give me the listener IP. The example below would show me the source IP. I can get the IP from the web interface at this location, http://xxx.xxx.xxx.xxx:8000/admin/listclients.xsl?mount=/dhantal, but that means I would have to scrape the web interface which I don't want to do. Reaz On 2020-09-21 5:27 p.m., Jordan Erickson wrote:> Hi Reaz, > > IP Address != Location of user in many cases. Think VPNs for instance. > > Of course if you're set on going that route, I'm pretty sure that > status-json.xsl (in your webroot) has the IP address option simply > added to a section that does not show it: > > <xsl:template match="icestats/source/source_ip"><xsl:if > test="not(following-sibling::*)">"dummy":null}</xsl:if></xsl:template> > > I could be wrong but you may be able to simply remove that line and > it'll work. I haven't tried that before so do it at your own risk ;) I > personally don't know how you would do that without modifying the xsl > file to display it. > > > Cheers, > Jordan Erickson > > > On 9/21/20 2:10 PM, Reaz Baksh wrote: >> Hello >> I’m new to Icecast and I’m using version 2.4.4. How would I be able to get a Jason file that has listener information specifically listener location or at least the IP address. I can get listener count but I’m looking for location through the IP. I need to write a php script to gather this information. I have checked the status-Jason.xsl and the xml2json.xsl but neither gives me that information. >> >> What would I have to modify and how, to get this? I would prefer not to modify any xsl file to get this if at all possible. >> >> Thanks >> >> Reaz >> _______________________________________________ >> Icecast-dev mailing list >> Icecast-dev at xiph.org >> http://lists.xiph.org/mailman/listinfo/icecast-dev >> > _______________________________________________ > Icecast-dev mailing list > Icecast-dev at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast-dev_______________________________________________ Icecast-dev mailing list Icecast-dev at xiph.org http://lists.xiph.org/mailman/listinfo/icecast-dev
Hi Reaz, "Too much work" "I should be able to get" "This should be easy" ... Feel free to learn the software you're using....or not. Please refrain from these kinds of remarks though as they don't motivate us to help you very much. Just my personal opinion. Cheers, Jordan Erickson On 9/22/20 8:43 AM, Reaz Baksh wrote:> Too much work. If I am able to see it on the web interface I should be able to get a Json or XML file with this in it. The reason I need this is to show current listeners and from where they are listening. I do this with the other streaming software without any modifications or adjustments. This should be easy. > > Reaz > >> On Sep 22, 2020, at 11:16 AM, <jorr at streamguys.com> <jorr at streamguys.com> wrote: >> >> What about scrapping the access logs for connections that have completed, or utilizing netstat outputs to get active listeners (minus sources)? >> >> Either of those options would get you remote IP addresses, both a slightly different view in that logs are after a connection closes, while netstat is while the connection is open. >> >> -----Original Message----- >> From: Icecast-dev <icecast-dev-bounces at xiph.org> On Behalf Of Reaz Baksh >> Sent: Monday, September 21, 2020 3:03 PM >> To: icecast-dev at xiph.org >> Subject: Re: [Icecast-dev] Listener stats >> >> Hello Jordan >> >> Thanks for the reply. I commented out all the fields in the status-json.xsl but it didn't give me the listener IP. The example below would show me the source IP. I can get the IP from the web interface at this location, http://xxx.xxx.xxx.xxx:8000/admin/listclients.xsl?mount=/dhantal, but that means I would have to scrape the web interface which I don't want to do. >> >> >> Reaz >> >>> On 2020-09-21 5:27 p.m., Jordan Erickson wrote: >>> Hi Reaz, >>> >>> IP Address != Location of user in many cases. Think VPNs for instance. >>> >>> Of course if you're set on going that route, I'm pretty sure that >>> status-json.xsl (in your webroot) has the IP address option simply >>> added to a section that does not show it: >>> >>> <xsl:template match="icestats/source/source_ip"><xsl:if >>> test="not(following-sibling::*)">"dummy":null}</xsl:if></xsl:template> >>> >>> I could be wrong but you may be able to simply remove that line and >>> it'll work. I haven't tried that before so do it at your own risk ;) I >>> personally don't know how you would do that without modifying the xsl >>> file to display it. >>> >>> >>> Cheers, >>> Jordan Erickson >>> >>> >>>> On 9/21/20 2:10 PM, Reaz Baksh wrote: >>>> Hello >>>> I’m new to Icecast and I’m using version 2.4.4. How would I be able to get a Jason file that has listener information specifically listener location or at least the IP address. I can get listener count but I’m looking for location through the IP. I need to write a php script to gather this information. I have checked the status-Jason.xsl and the xml2json.xsl but neither gives me that information. >>>> >>>> What would I have to modify and how, to get this? I would prefer not to modify any xsl file to get this if at all possible. >>>> >>>> Thanks >>>> >>>> Reaz >>>> _______________________________________________ >>>> Icecast-dev mailing list >>>> Icecast-dev at xiph.org >>>> http://lists.xiph.org/mailman/listinfo/icecast-dev >>>> >>> _______________________________________________ >>> Icecast-dev mailing list >>> Icecast-dev at xiph.org >>> http://lists.xiph.org/mailman/listinfo/icecast-dev >> _______________________________________________ >> Icecast-dev mailing list >> Icecast-dev at xiph.org >> http://lists.xiph.org/mailman/listinfo/icecast-dev >> > > _______________________________________________ > Icecast-dev mailing list > Icecast-dev at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast-dev >
Good afternoon, On Tue, 2020-09-22 at 11:43 -0400, Reaz Baksh wrote:> Too much work.I would like to refer to Jordan Erickson's comment here.> If I am able to see it on the web interface I should be able to get a Json or XML file with this in it.Why not just use the API? Remove the ".xsl" from any URL in the admin interface and get the raw XML. The rendered webinterface is just that: XSLT applied to the API.> This should be easy.As easy as asking nicely. With best regards,> > On Sep 22, 2020, at 11:16 AM, <jorr at streamguys.com> <jorr at streamguys.com> wrote: > > > > What about scrapping the access logs for connections that have completed, or utilizing netstat outputs to get active listeners (minus sources)? > > > > Either of those options would get you remote IP addresses, both a slightly different view in that logs are after a connection closes, while netstat is while the connection is open. > > > > -----Original Message----- > > From: Icecast-dev <icecast-dev-bounces at xiph.org> On Behalf Of Reaz Baksh > > Sent: Monday, September 21, 2020 3:03 PM > > To: icecast-dev at xiph.org > > Subject: Re: [Icecast-dev] Listener stats > > > > Hello Jordan > > > > Thanks for the reply. I commented out all the fields in the status-json.xsl but it didn't give me the listener IP. The example below would show me the source IP. I can get the IP from the web interface at this location, http://xxx.xxx.xxx.xxx:8000/admin/listclients.xsl?mount=/dhantal, but that means I would have to scrape the web interface which I don't want to do. > > > > > > Reaz > > > >> On 2020-09-21 5:27 p.m., Jordan Erickson wrote: > >> Hi Reaz, > >> > >> IP Address != Location of user in many cases. Think VPNs for instance. > >> > >> Of course if you're set on going that route, I'm pretty sure that > >> status-json.xsl (in your webroot) has the IP address option simply > >> added to a section that does not show it: > >> > >> <xsl:template match="icestats/source/source_ip"><xsl:if > >> test="not(following-sibling::*)">"dummy":null}</xsl:if></xsl:template> > >> > >> I could be wrong but you may be able to simply remove that line and > >> it'll work. I haven't tried that before so do it at your own risk ;) I > >> personally don't know how you would do that without modifying the xsl > >> file to display it. > >> > >> > >> Cheers, > >> Jordan Erickson > >> > >> > >>> On 9/21/20 2:10 PM, Reaz Baksh wrote: > >>> Hello > >>> I’m new to Icecast and I’m using version 2.4.4. How would I be able to get a Jason file that has listener information specifically listener location or at least the IP address. I can get listener count but I’m looking for location through the IP. I need to write a php script to gather this information. I have checked the status-Jason.xsl and the xml2json.xsl but neither gives me that information. > >>> > >>> What would I have to modify and how, to get this? I would prefer not to modify any xsl file to get this if at all possible.-- Philipp Schafft (CEO/Geschäftsführer) Telephon: +49.3535 490 17 92 Löwenfelsen UG (haftungsbeschränkt) Registration number: Bickinger Straße 21 HRB 12308 CB 04916 Herzberg (Elster) VATIN/USt-ID: Germany DE305133015 -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 490 bytes Desc: This is a digitally signed message part URL: <http://lists.xiph.org/pipermail/icecast-dev/attachments/20200922/bb8d868f/attachment-0001.sig>