Subj : Getting the BBS IP address To : Codefenix From : Digital Man Date : Tue Sep 12 2023 12:02 pm Re: Getting the BBS IP address By: Codefenix to Digital Man on Tue Sep 12 2023 09:03 am > Re: Getting the BBS IP address > By: Digital Man to Codefenix on Mon Sep 11 2023 04:34 pm > > DM> Is there a client connected? It's certainly not 0.0.0.0 for me: > > Yes, mine. :) I'm running a script containing the > client.socket.local_ip_address while logged into the BBS. Running a script how? What's in the script? I created exec/test.js containing a single line: print(client.socket.local_ip_address); And then when I run that script from the BBS, I get the IP address I expect: ;exec ?test.js 71.95.196.36 > DM> ;eval > DM> Parameter(s): client.socket.local_ip_address > DM> Result (string): 71.95.196.36 > > Interesting. I get a different result when I call > client.socket.local_ip_address that way as opposed to calling it within a > script. I do not. > ;EVAL > Parameter(s): client.socket.local_ip_address > Result (string): 192.168.1.9 > > Also, it's returning the behind-the-router IP for me, rather than the > outward-facing IP, which it seems like it's supposed to do given your > output. My servers aren't behind NAT, so that's expected. I guess if you want to find the *public* IP address associated with your hostname and your server is behind a NAT, then I guess the method you originally provided is (only?) way. -- digital man (rob) Rush quote #47: All of us get lost in the darkness, dreamers learn to steer by the stars Norco, CA WX: 83.4øF, 45.0% humidity, 0 mph E wind, 0.00 inches rain/24hrs --- þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net .