Topics

Beginner Questions: spyserver config

Ken Alexander
 

OK,

I left the bind_host and bind_port settings as I found them in the spyserver.config file.  Double clicked the spyserver icon in the folder.

1.  It's running from inside the Downloads folder.  Is that OK?  Isn't there a Program Files folder somewhere, just to keep things orderly?

2.  There's no visible indication that spyserver is running.  You double click the icon and, nothing happens.  How do you know it's running?  How do you turn it off?

Anyway, I started spyserver and connected my Pi to a notebook via a LAN cable and ran SDR#.  I selected spyserver as the source.  bind_host was set to 127.0.0.5 and port was set to 5555.  I changed bind_host to 0.0.0.0 to match what was in the spyserver.config file.  See attachment Setting.jpg

I clicked Connect and got the error in attachment Error.jpg, which I don't understand.

I went back into spyserver.config and changed bind_host back to 127.0.0.5 and changed bind_port to 555 instead of 5555-6666 as I originally found it.

I killed spyserver in Task Manager and re-started it so it would take the new settings (attachment Setting2.jpg), double checked the settings in SDR# and clicked Connect and got a new error message (attachment Error2.jpg)

Somebody help please.  This seems relatively simple but it's not working out that way.

Thanks again,

Ken Alexander
So Phisai, Thailand
Blog:  bueng-ken.com

prog
 

On Wed, Feb 20, 2019 at 12:08 PM, Ken Alexander wrote:
Somebody help please.  This seems relatively simple but it's not working out that way.
As I said: If you don't understand what you are doing, leave EVERYTHING to the default, including the address in SDR#, and things will magically work.

Ken Alexander
 

So 0.0.0.0 in Spyserver  and 176.0.0.5 in SDR# is OK?  Really?  OK, I'll give it a try!

Ken


On Wed, Feb 20, 2019 at 11:12 AM prog <info@...> wrote:
On Wed, Feb 20, 2019 at 12:08 PM, Ken Alexander wrote:
Somebody help please.  This seems relatively simple but it's not working out that way.
As I said: If you don't understand what you are doing, leave EVERYTHING to the default, including the address in SDR#, and things will magically work.

prog
 

The default in SDR# is 127.0.0.1 (localhost).
Try getting something to work locally and get familiar with it before stepping forward.

Ken Alexander
 

All I want is for this to work inside my house.  I'm not even thinking about the internet right now.

I tried again and got this:  Could not connect to SDR://127.0.0.1:5555

Ken



On Wed, Feb 20, 2019 at 11:42 AM prog <info@...> wrote:
The default in SDR# is 127.0.0.1 (localhost).
Try getting something to work locally and get familiar with it before stepping forward.

hmarais@...
 

Replace 127.0.0.1 with the IP address of the Raspberry PI when connecting from SDR#. Leave bind_host as 0.0.0.0 in the Spyserver config on the Raspberry PI.

Martin Smith
 

SDR:// 127.0.0.1:5555 ( http://127.0.0.1:5555 )
127.0.0.1 is called the loopback address, you could think of it as a short hand for the machine that you are sitting in front of and physically typing on.
So the question for you would be, is Spyserver running on the same windows machine that SDR# is running on ?

Martin Smith
 

On Wed, Feb 20, 2019 at 11:08 AM, Ken Alexander wrote:


back to 127.0.0.5 and changed bind_port to 555
127.0.0.5 is not the loopback address (127.0.0.1 is the default loopback address). And historically any port number lower than 1024 requires root access for a process to bind to under most UNIX distributions. Running any process as root while bound to a port is considered a much much higher security risk than running any process as user account of some description.

If you bind any process to a port on the loopback address, then for security only local programs physically running on that machine can access that port on the loopback address. loopback addresses are not remotely accessible across a network they are local to the machine. You should use the default bind_host of 0.0.0.0 which will bind the process to the loopback address AND the network accessible address of the machine. If you only want your spyserver accessible locally on your home network then do not enable port forwarding on your home router for that port and also set "list_in_directory = 0" in the spyserver.config file.

Mike Gould <mikeyg123@...>
 

As a bind address 0.0.0.0 means all interfaces. This will almost always just work 
127.0.0.1 means the local machine. This will only work if sdr# is running on the same machine as spyserver



On Wed, 20 Feb 2019 at 12:27, Ken Alexander <ve3hls@...> wrote:
All I want is for this to work inside my house.  I'm not even thinking about the internet right now.

I tried again and got this:  Could not connect to SDR://127.0.0.1:5555

Ken



On Wed, Feb 20, 2019 at 11:42 AM prog <info@...> wrote:
The default in SDR# is 127.0.0.1 (localhost).
Try getting something to work locally and get familiar with it before stepping forward.

Ken Alexander
 

Spyserver is running on a Raspberry Pi.

SDR# is running on a Windows laptop.

They are connected by a short ethernet cable.

Does that change how things should be set?  There were no instructions provided so I have to rely on the group, and sorry to say but I'm a lot more confused than I was when I started.

Thanks, but I've barely be at this a week.  Maybe you could pretend you're talking to an 8-year old? 😜


On Wed, Feb 20, 2019 at 3:05 PM Mike Gould <mikeyg123@...> wrote:
As a bind address 0.0.0.0 means all interfaces. This will almost always just work 
127.0.0.1 means the local machine. This will only work if sdr# is running on the same machine as spyserver



On Wed, 20 Feb 2019 at 12:27, Ken Alexander <ve3hls@...> wrote:
All I want is for this to work inside my house.  I'm not even thinking about the internet right now.

I tried again and got this:  Could not connect to SDR://127.0.0.1:5555

Ken



On Wed, Feb 20, 2019 at 11:42 AM prog <info@...> wrote:
The default in SDR# is 127.0.0.1 (localhost).
Try getting something to work locally and get familiar with it before stepping forward.

--

Joe M.
 

Yes, it does. Connect to the IP of the RPi.

It will likely be a 192.168.x.x address. Port 5555.

You will enter that in the format 192.168.x.x:5555

Joe M.

On 2/20/2019 10:47 AM, Ken Alexander wrote:
Spyserver is running on a Raspberry Pi.

SDR# is running on a Windows laptop.

They are connected by a short ethernet cable.

Does that change how things should be set?

Ken Alexander
 

127.0.0.1:5555 is what was set up already in SDR# on my Windows laptop, which is connected to my Pi with an ethernet cable.

Spyserver, running on my Pi is set to 0.0.0.0 and for ports it says 5555-6666, which I assume means...well, I don't really know what it means.

Trying to connect results in the Error message I already posted.

If I change the setting in SDR# from 127.0.0.1 to 0.0.0.0 to match what is set in spyserver.config I still get an Error message.  See the attachments in a previous post.

Setting 127.0.0.1 in both spyserver.config AND in SDR# gives me the same error message.

There are only so many possible combinations here.  I've tried them all and nothing works.

This ought to be really simple and I don't understand why it's not working.

Ken

On Wed, Feb 20, 2019 at 2:39 PM <hmarais@...> wrote:
Replace 127.0.0.1 with the IP address of the Raspberry PI when connecting from SDR#. Leave bind_host as 0.0.0.0 in the Spyserver config on the Raspberry PI.

Ken Alexander
 

No.  I can't envision a scenario where I would want to do that.  I'd just plug my Airspy into my computer and start SDR#.

Google "loopback address"

On Wed, Feb 20, 2019 at 2:39 PM Martin Smith via Groups.Io <martin_z_smith=yahoo.ie@groups.io> wrote:
> SDR:// 127.0.0.1:5555 ( http://127.0.0.1:5555 )
127.0.0.1 is called the loopback address, you could think of it as a short hand for the machine that you are sitting in front of and physically typing on.
So the question for you would be, is Spyserver running on the same windows machine that SDR# is running on ?



Ken Alexander
 

Sorry.  127.0.0.5 was a typo.  It always was 127.0.0.1.


On Wed, Feb 20, 2019 at 2:39 PM Martin Smith via Groups.Io <martin_z_smith=yahoo.ie@groups.io> wrote:
On Wed, Feb 20, 2019 at 11:08 AM, Ken Alexander wrote:

>
> back to 127.0.0.5 and changed bind_port to 555
>
127.0.0.5 is not the loopback address (127.0.0.1 is the default loopback address). And historically any port number lower than 1024 requires root access for a process to bind to under most UNIX distributions. Running any process as root while bound to a port is considered a much much higher security risk than running any process as user account of some description.

If you bind any process to a port on the loopback address, then for security only local programs physically running on that machine can access that port on the loopback address. loopback addresses are not remotely accessible across a network they are local to the machine. You should use the default bind_host of 0.0.0.0 which will bind the process to the loopback address AND the network accessible address of the machine. If you only want your spyserver accessible locally on your home network then do not enable port forwarding on your home router for that port and also set "list_in_directory = 0" in the spyserver.config file.



Tom Snyder
 


I think you need a crossover ethernet cable for communication to take place.  Or use a hub.  A straight ethernet cable means talk is connected to talk and listen is connected to listen.  You need talk-listen and listen-talk.


From: main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe M. <mch@...>
Sent: Wednesday, February 20, 2019 09:21
To: main@airspy.groups.io
Subject: Re: [airspy] Beginner Questions: spyserver config
 
Yes, it does. Connect to the IP of the RPi.

It will likely be a 192.168.x.x address. Port 5555.

You will enter that in the format 192.168.x.x:5555

Joe M.

On 2/20/2019 10:47 AM, Ken Alexander wrote:
> Spyserver is running on a Raspberry Pi.
>
> SDR# is running on a Windows laptop.
>
> They are connected by a short ethernet cable.
>
> Does that change how things should be set?



Joe M.
 

Most PCs will auto-configure so the crossover is not needed.

But if the correct IP is not used, it will not matter if they are connected by a wet noodle.

Joe M.

On 2/20/2019 12:29 PM, Tom Snyder wrote:

I think you need a crossover ethernet cable for communication to take
place. Or use a hub. A straight ethernet cable means talk is connected
to talk and listen is connected to listen. You need talk-listen and
listen-talk.

------------------------------------------------------------------------
*From:* main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe
M. <mch@...>
*Sent:* Wednesday, February 20, 2019 09:21
*To:* main@airspy.groups.io
*Subject:* Re: [airspy] Beginner Questions: spyserver config
Yes, it does. Connect to the IP of the RPi.

It will likely be a 192.168.x.x address. Port 5555.

You will enter that in the format 192.168.x.x:5555

Joe M.

On 2/20/2019 10:47 AM, Ken Alexander wrote:
Spyserver is running on a Raspberry Pi.

SDR# is running on a Windows laptop.

They are connected by a short ethernet cable.

Does that change how things should be set?



<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
Virus-free. www.avg.com
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>


<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

Martin Smith
 

On Wed, Feb 20, 2019 at 05:30 PM, Ken Alexander wrote:


which is connected to my Pi with an ethernet cable.
So is the connection that you have ?
Raspberry pi<---- ethernet cable ----> Windows PC
Or is it
Raspberry pi<---- ethernet cable ---->broadband router<--- ethernet cable ---> Windows PC

The first setup would be unusual and mean that neither device would by default be assigned an IP address. A private static IP address would manually need to be configured on each machine and a static route manually added to each machines routing tables ("netstat -rn" to view the current routing tables) to enable packets to transfer across the cable. It would not be a typical configuration. (search for "how to add static route in linux permanently" and "how to add static route in windows permanently", if that is the option that you want to use and you really should learn a bit more about networking to understand why and what you are actually doing.). Another less slightly complex way would be to manually configure a DHCP server on the Raspberry pi and have it automatically configure the windows machine when connected, but a private network range different than any used on the PC would need to be used, and windows may get confused if not done exactly. Search for "how to connect to a raspberry pi directly with an Ethernet cable" and be prepared to screw up a few times, Either way would not be trivial to configure for a beginner.

The second scenario would be the typical configuration for the vast majority of people. The broadband router which is running a DHCP (dynamic host configuration protocol) service would automatically allocate each device that was connected a unique IP address along with a subnet mask, default router, a network address and a broadcast address. And you can connect to your router typically through a web interface and find out what IP addresses have been allocated.

Lets keep this very simple, what what way are your network cables connected ? and
1 On your windows PC what is the value for "IPv4 Address" ?
open a command terminal by pressing the windows key and r at the same time, then cmd.exe and hit the enter key and in the command terminal type "ipconfig" and hit enter.
2 On the Raspberry Pi what is your inet for eth0
Open a shell/xterm/terminal and type "/sbin/ifconfig -a" and hit enter.

Without knowing what your setup actually is no one can really help you.

Tom Snyder
 

On what do you base your statement of: "Most PCs will auto-configure so the crossover is not needed", I've never seen any literature to support.


From: main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe M. <mch@...>
Sent: Wednesday, February 20, 2019 09:40
To: main@airspy.groups.io
Subject: Re: [airspy] Beginner Questions: spyserver config
 
Most PCs will auto-configure so the crossover is not needed.

But if the correct IP is not used, it will not matter if they are
connected by a wet noodle.

Joe M.

On 2/20/2019 12:29 PM, Tom Snyder wrote:
>
> I think you need a crossover ethernet cable for communication to take
> place.  Or use a hub.  A straight ethernet cable means talk is connected
> to talk and listen is connected to listen.  You need talk-listen and
> listen-talk.
>
> ------------------------------------------------------------------------
> *From:* main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe
> M. <mch@...>
> *Sent:* Wednesday, February 20, 2019 09:21
> *To:* main@airspy.groups.io
> *Subject:* Re: [airspy] Beginner Questions: spyserver config
> Yes, it does. Connect to the IP of the RPi.
>
> It will likely be a 192.168.x.x address. Port 5555.
>
> You will enter that in the format 192.168.x.x:5555
>
> Joe M.
>
> On 2/20/2019 10:47 AM, Ken Alexander wrote:
>> Spyserver is running on a Raspberry Pi.
>>
>> SDR# is running on a Windows laptop.
>>
>> They are connected by a short ethernet cable.
>>
>> Does that change how things should be set?
>
>
>
>
> <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
>        Virus-free. www.avg.com
> <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
>
>
> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
>



Joe M.
 

Experience. Of course, I still find the PCs I purchase nearly all have serial ports despite people telling me they have not been available for over 10 years on a PC (purchase quantity over the past 10 years is approaching 100 if not more). The only exceptions to this are a Surface tablet).

Have you tried it?

Nearly any device that requires an IP to be set has a default. I always set it by connecting a PC to it, set it as needed, then put that PC back on my network and connect the new device. That tactic has yet to fail.

When you connect two PCs direct to each other, one will act as a DHCP server and assign an IP to the other. I can't say the RPi does this, but I seem to recall that it will.

I do know of at least one bug on the RPi. For the VNC server, if you clone the SD card then change the RPI's IP, the VNC Server will still only respond to the original IP. Even the Real VNC people don't have an answer for that one.

Joe M.

On 2/20/2019 5:11 PM, Tom Snyder wrote:
On what do you base your statement of: "Most PCs will auto-configure so
the crossover is not needed", I've never seen any literature to support.

------------------------------------------------------------------------
*From:* main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe
M. <mch@...>
*Sent:* Wednesday, February 20, 2019 09:40
*To:* main@airspy.groups.io
*Subject:* Re: [airspy] Beginner Questions: spyserver config
Most PCs will auto-configure so the crossover is not needed.

But if the correct IP is not used, it will not matter if they are
connected by a wet noodle.

Joe M.

On 2/20/2019 12:29 PM, Tom Snyder wrote:

I think you need a crossover ethernet cable for communication to take
place. Or use a hub. A straight ethernet cable means talk is connected
to talk and listen is connected to listen. You need talk-listen and
listen-talk.

------------------------------------------------------------------------
*From:* main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe
M. <mch@...>
*Sent:* Wednesday, February 20, 2019 09:21
*To:* main@airspy.groups.io
*Subject:* Re: [airspy] Beginner Questions: spyserver config
Yes, it does. Connect to the IP of the RPi.

It will likely be a 192.168.x.x address. Port 5555.

You will enter that in the format 192.168.x.x:5555

Joe M.

On 2/20/2019 10:47 AM, Ken Alexander wrote:
Spyserver is running on a Raspberry Pi.

SDR# is running on a Windows laptop.

They are connected by a short ethernet cable.

Does that change how things should be set?



<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
Virus-free.www.avg.com <http://www.avg.com>
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>


<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


Micah Stevens <micahstev@...>
 

It's called the MDI-X spec. Most modern interfaces support it: https://en.wikipedia.org/wiki/Ethernet_crossover_cable#Automatic_crossover


.. but not all. It's important to be aware of the issue as you suggested.


On 2/20/19 2:11 PM, Tom Snyder wrote:
On what do you base your statement of: "Most PCs will auto-configure so the crossover is not needed", I've never seen any literature to support.


From: main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe M. <mch@...>
Sent: Wednesday, February 20, 2019 09:40
To: main@airspy.groups.io
Subject: Re: [airspy] Beginner Questions: spyserver config
 
Most PCs will auto-configure so the crossover is not needed.

But if the correct IP is not used, it will not matter if they are
connected by a wet noodle.

Joe M.

On 2/20/2019 12:29 PM, Tom Snyder wrote:
>
> I think you need a crossover ethernet cable for communication to take
> place.  Or use a hub.  A straight ethernet cable means talk is connected
> to talk and listen is connected to listen.  You need talk-listen and
> listen-talk.
>
> ------------------------------------------------------------------------
> *From:* main@airspy.groups.io <main@airspy.groups.io> on behalf of Joe
> M. <mch@...>
> *Sent:* Wednesday, February 20, 2019 09:21
> *To:* main@airspy.groups.io
> *Subject:* Re: [airspy] Beginner Questions: spyserver config
> Yes, it does. Connect to the IP of the RPi.
>
> It will likely be a 192.168.x.x address. Port 5555.
>
> You will enter that in the format 192.168.x.x:5555
>
> Joe M.
>
> On 2/20/2019 10:47 AM, Ken Alexander wrote:
>> Spyserver is running on a Raspberry Pi.
>>
>> SDR# is running on a Windows laptop.
>>
>> They are connected by a short ethernet cable.
>>
>> Does that change how things should be set?
>
>
>
>
> <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
>        Virus-free. www.avg.com
> <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
>
>
> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
>