Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1
    Master Untangler
    Join Date
    Jan 2011
    Posts
    928

    Default why does this work?

    so I've got this little board designed to feed files to older CNC milling machines that have only a serial port. it has a little SD card and an FTP server, so you FTP files to the memory card and then you can feed those files to the mill via RS-232.

    anyhow, the device doesn't even have a DHCP client, it comes pre-configured to an IP of 192.168.1.111 with no dns or gateway set (both set to 0.0.0.0, confirmed on the little 4-line LCD display panel, and also looking at the .ini file the device uses when it boots).

    in order to access the device, I added 192.168.1.1/24 as an alias on my untangle's internal interface, forgetting for a moment that without a gateway the device would have no route back to my network...

    yet it works anyway. I can ping and FTP to the device no problem.

    it shouldn't work! what am I missing?

  2. #2
    Untangle Junkie dmorris's Avatar
    Join Date
    Nov 2006
    Location
    San Carlos, CA
    Posts
    16,490

    Default

    If you added an alias it should work as that network is now local.
    Attention: Support and help on the Untangle Forums is provided by volunteers and community members like yourself.
    If you need Untangle support please call or email support@untangle.com

  3. #3
    Master Untangler
    Join Date
    Jan 2011
    Posts
    928

    Default

    but how does the 192.168.1.111 device know how to reach my computer at 192.168.27.140 without a gateway? sure it can receive packets from my computer though the untangle router, but it shouldn't be able to respond back.

  4. #4
    Untangle Junkie dmorris's Avatar
    Join Date
    Nov 2006
    Location
    San Carlos, CA
    Posts
    16,490

    Default

    my guess would be that its using /16
    Attention: Support and help on the Untangle Forums is provided by volunteers and community members like yourself.
    If you need Untangle support please call or email support@untangle.com

  5. #5
    Master Untangler
    Join Date
    Jan 2011
    Posts
    928

    Default

    I thought of that too... but it's not. The .ini file and on-screen display both said it's using 255.255.255.0 (admittedly I don't know if the on-screen display actually looks at the current IP settings or if it's simply parroting the .ini file). I realize there has to be some explanation somewhere, something odd about the device's IP stack or it's using settings internally that don't match the .ini file. Either that, or it's magic!

    This morning I'm setting up a wifi bridge which defaults to 192.168.9.2. Adding the alias 192.168.9.1/24 didn't produce the same magic effect. The Untangle can ping the device, but my workstation can't.

    I have another of the same FTP device to setup tomorrow, I'll see if the same magic happens again.
    (I think I'll try manually setting my own netmask to /16, see if I can talk to the device without the alias on the untangle router... that would prove the device is using a /16 or bigger internally, despite what the .ini file says)
    Last edited by johnsonx42; 06-15-2017 at 09:57 AM.

  6. #6
    Untangle Ninja jcoehoorn's Avatar
    Join Date
    Mar 2010
    Location
    York, NE
    Posts
    1,373

    Default

    With just one network port and hard-coded IP, it might just always send everything out that one interface.
    Five time Microsoft ASP.Net MVP managing a Lenovo RD330 / E5-2420 / 8GB with Untangle 12.2 to protect 200Mbits for ~400 residential college students and associated staff and faculty

  7. #7
    Untangle Ninja sky-knight's Avatar
    Join Date
    Apr 2008
    Location
    Phoenix, AZ
    Posts
    21,643

    Default

    I'm with Dirk, I think the magic box is ignoring the mask configuration. Only way to know for sure is a packet capture.

    But, the OP is correct to wonder, if the device is on the 192.168.1.0/24 network, a device outside that network will not be able to communicate with it if it has no routes, or gateways. That is, unless the router that is on both segment performs NAT, then it would work because "it's local".
    Rob Sandling, BS:SWE, MCP
    NexgenAppliances.com
    Phone: 866-794-8879 x201
    Email: support@nexgenappliances.com

  8. #8
    Untangle Ninja dwasserman's Avatar
    Join Date
    Jun 2008
    Location
    Argentina
    Posts
    4,270

    Default

    Maybe ARP?
    From a workstation that can access to the device do an "arp -a" (windows)
    The world is divided into 10 kinds of people, who know binary and those not

  9. #9
    Master Untangler
    Join Date
    Jan 2011
    Posts
    928

    Default

    mystery partially solved - the device does appear to be using a wide subnet mask despite being told to use /24. I manually set my workstation's IP to 192.168.27.140/16, and I can talk to the device at 192.168.1.111 with no routing.

    edit: for further testing, I set the device's IP to 192.168.1.94/25, and set the gateway to 192.168.1.1 just to make sure the behavior wasn't some side-effect of having the gateway set to 0.0.0.0, and I can still access the device from 192.168.27.140/16. So it's definitely disregarding the "NETMASK" setting in the .ini and using at least /16 if not bigger

    edit2: yep, as far as I can tell from testing, this thing is using a /0 netmask no matter what it's .ini file says
    Last edited by johnsonx42; 06-16-2017 at 12:17 PM.

  10. #10
    Untangle Ninja sky-knight's Avatar
    Join Date
    Apr 2008
    Location
    Phoenix, AZ
    Posts
    21,643

    Default

    That's strange, because if it's actually using a /0, the device will think all traffic is local, it means it would never use a gateway... ever.
    Rob Sandling, BS:SWE, MCP
    NexgenAppliances.com
    Phone: 866-794-8879 x201
    Email: support@nexgenappliances.com

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

SEO by vBSEO 3.6.0 PL2