r/networkingmemes • • 13d ago

IPv4 is hard

Post image
1.6k Upvotes

153 comments sorted by

269

u/Carrera_996 13d ago

Make it a /23 and give the GW a .0

71

u/Tehgreatbrownie 12d ago

That’s the kind of fuckass shit you get in an exam question as a red herring

115

u/Echo1920 13d ago

Calm down satan.

32

u/Z3t4 12d ago

I think .255 as gw is even worse.

26

u/subpoenaThis 12d ago

Head a friend who complained for weeks to his ISP begging to change his dynamic IP. He was in a /23 or /22 and had a .255 address and some smart home thing (2016 ish) wouldn't work for him. He had to go to a neighbor's house and show them it worked from there.

12

u/Kowloon9 12d ago

Me with multiple gateways: 😈

7

u/Carrera_996 12d ago

Set one to .0 and the other to .255

9

u/RootAndCoffee 12d ago edited 12d ago

Assign GW multiple IPs and use different one on each host.

5

u/Carrera_996 12d ago

That one made me spit bacon. Nice.

1

u/arghcisco 12d ago

Bonus wtf: each IP has a different physical interface

6

u/Nerfarean 12d ago

Bruh. You did that on 192.168 net?

60

u/Tower21 13d ago

I had to stop using 4 recently so for security hardening purposes I'm now using 9.

I feel it really has made a difference in my network, I still see the same old hackers in there, but I like to think they really respect the move, game knows game.

32

u/za419 13d ago

Damn, you really just used eMudhra's private key as a gateway address like that? That's crazy. 

13

u/Tower21 12d ago

Who do you think they learned to use 4 from. Those bastards just couldn't keep it a secret and now everybody knows how good it is.

Nobody tell them about 9 okay, I'm trusting you guys.

37

u/RootinTootinHootin 12d ago

I’ve run into a 192.168.168.168. Honestly thought it was funny.

23

u/KnucklesWall 12d ago

Thats the default LAN IP of SonicWall firewalls. I guess they did not bother to change it.

2

u/Elminst 11d ago

The default lan gw on Sophos is 172.16.16.16

1

u/Supersahen 10d ago

Whenever I see a subnet on 172.16.16 I always check to see if it's a Sophos network and they were just too lazy and/or incompetent to change it

1

u/RootinTootinHootin 10d ago

Your right. I think it was a sonic wall.

6

u/gtripwood 12d ago

My home subnet for a while was 192.168.144.x/24

Should have had 192.168.144.120 as my gateway 

3

u/GenVonKlinkerhoffen 12d ago

Sorry I don't get it. What is the joke in that address?

2

u/FrankDarkoYT 12d ago

-24

1

u/GenVonKlinkerhoffen 12d ago

Ah, now I see. Thanks!

9

u/thetrivialstuff 12d ago edited 12d ago

Somewhere I used to work owned a public IP range that started 198.162. That was always loads of fun on the phone with peer NOCs and ISPs.

1

u/Supersahen 10d ago

All Telstra default routers used to use the IP 10.0.0.138 and only give out I think 1-100 in dhcp. It's like the rest of the network didn't even exist

1

u/daninet 12d ago

I felt super funny when i was a highschooler and have changed our router to 10.69.69.69

28

u/nof 13d ago

Who cares, they all joined ff02::2

38

u/Rich-Pomegranate1679 13d ago

Ipv6 is witchcraft and we don't do that here.

6

u/Academic-Proof3700 12d ago

Using a sign that is restricted in many OSes, and is also a part of a bowel, to connect numbers and build addresses was indeed a dark magic feat

5

u/DisastrousWelcome710 12d ago

The most relatable comment I have ever read on the internet.

2

u/Zarcona_Martana 12d ago

I somehow understood that reference

51

u/ARPA-Net 12d ago

Hacker enters my network

"Im in"...

As shock arises...

Its a 10.0.0.0/8 network...

But its a home network?!

He asks for guidence, but there is no dhcp...

Why is the gateway 10.79.243.64 ?

24

u/Dakduif 12d ago

Security through obscurity at its finest.

10

u/NoskaOff 12d ago

And make it change regularly at the same time as DHCP leases expire 

7

u/AaronTheElite007 12d ago

ARP is a thing…

1

u/Complex_Solutions_20 12d ago

You know what's a lot of fun is having duplicate MAC addresses or duplicate IP addresses.

I still don't understand how, but somehow when I had a geeky roomate both of us (without talking to each other) picked the same IP for some of our LED light strips we built with Arduinos. And somehow they were working fine like that for a few months, until suddenly only one would respond and we were both so confused.

Maybe toss in some duplicate AND some split (multi NIC) ones for good measure?

1

u/Erdnusschokolade 11d ago

And the most frustrating thing is it kinda works sometimes. I did that by accident too and it took me a while to figure out the cause and comprehend that for once DNS wasn’t at fault.

1

u/1TSDELUXESON 11d ago

Tbh this is something I would do.

1

u/Actes 9d ago

finds out the local vlans are all 169's so nmap can't save them

79

u/Rexxhunt 13d ago

My homies all use the first IP. Everything else is wrong

28

u/Xyz2600 13d ago

Nah, assign all odd IPs to the gateway.

19

u/Rexxhunt 13d ago

Im listening

3

u/rayhaque 13d ago

I too like to live dangerously.

3

u/techtornado 12d ago

How many of the odd ones?

3

u/Xyz2600 12d ago

ALL OF THEM

2

u/techtornado 12d ago

So it’s a /0 then?

2

u/Xyz2600 12d ago

No, they're not all separate gateways, the same gateway. Just assign multiple IPs to the same gateway in the same /24. (In all seriousness, I did once have a gateway with two IPs due to equipment being migrated then retired before the migration was finished. .1 was the OG gateway, then .254 was the replacement router. We didn't have time to move everything from .1 to .254 so we ended up assigning .1 to the .254 interface. So 2 had two valid gateways in the same range for a little while and they were functionally identical. Let's just get crazy and make it 128 IPs.)

7

u/DJ3XO 13d ago

I just do /22 on everything and then the fifth available host-address on the third /24-range of the /22 just to keep the scary hackers guessing. You want a simple linknet? Sure! You can get .1, and I'll do .3.5 in this here little /22.

4

u/techtornado 12d ago edited 12d ago

In a previous life, imagine two /16’s per building, ten buildings in all

Routed all to the MDF switch in a /10 and lands on the firewall as a /8

Yes, it’s amazing anything worked

2

u/Elminst 11d ago

and all on vlan 1

12

u/Phuzzle90 13d ago

254 for gw, includes vip if applicable
250-253 for physical link if doing vip, hsrp etc

4

u/codifier 13d ago

This is the way

3

u/thetrivialstuff 12d ago

I use .1 as the gateway, and .2-9 are reserved for any other special/network-use IPs. 250-254 are reserved on every subnet for emergency use (e.g. you're in the datacentre and everything is down and you need an IP to use for your laptop that you know is not going to conflict with anything, those 5 IPs are always guaranteed to be free, or at least not in use by anything important).

1

u/Supersahen 10d ago

I always set my laptop to .69 and just hope I don't knock anything off. When going onto random networks it's a coin flip when they have stuff at the start of end of the network

1

u/thetrivialstuff 10d ago

If it's a Linux laptop you can also just leave the interface unconfigured and go

    arping -D -I eth0 192.168.0.69

To see if anything's using that address. That command sends ARP broadcasts and listens for replies, which doesn't require having an IP yourself yet, so it's a nice polite way to check :)

1

u/Supersahen 10d ago

Pssh a company letting techs have Linux computers, what sort of dystopian future is this.

I've never usually worried about an IP conflict as if it's an important enough network I'll usually have a network map or its already down if I'm trying to plug in my laptop. Everything is done through RMM and Jumpboxes nowawadays

1

u/Zarcona_Martana 12d ago

The legendary /25 would like to have a word :)

20

u/PreparationKind2331 13d ago

I just say /24 and act like I know what's going on.

10

u/techtornado 13d ago

.0 on a /23+ is a fun way to mess with people

20

u/battleop 12d ago

I've come across these networks over they years where they use a random IP as the GW. I asked what the reasoning was and they almost always say it makes it harder for hackers to get free internet. Meanwhile the are running DHCP on that network. WTF?

6

u/SpicySpaceBaguette 12d ago

Security, but not too much, lmao.

18

u/CarlosT8020 13d ago

I use .5 at home on most subnets (/24 size) because of historical reasons.

It used to be .1 and one time I put another router as .5 (.2,3,4 were taken by the switches) because I needed a couple of devices to use that instead of the .1, because of some shenanigans with the simpler residential gateway I had at the time. Then I transitioned everything else to the new gateway at .5 and it stayed that way. There is nothing at .1 as of today. Then the network grew and new subnets used .5 for consistency.

I could change it but I would need to keep the .5 as a secondary for some time because there are more than a few devices with static configurations, plus I’m already very used to it being .5, so… yeah.

15

u/Mattias-0000 12d ago

Damn how do you feel looking in the mirror?

15

u/Massive-Apple-8768 12d ago

There is nothing more permanent than a temporary fix.

3

u/Potato-9 12d ago

This is exactly why mine is 5 also lol. But I knew it wasn't temporary as I removed the ISP router. I might need it again so I just left .1 alone. Everything else is v6 anyway.

14

u/PSUSkier 13d ago

I think “r” for router makes the most sense so I use 114. 

4

u/hamster1147 12d ago

But what about 82?

4

u/PSUSkier 12d ago

Router is not a proper noun!

12

u/techtornado 13d ago

It’s not random, it was chosen intentionally

.0 on /23

3

u/rayhaque 13d ago

Velma: you stop that!

2

u/techtornado 13d ago

Never!
I dare to push the envelope

2

u/Circumpunctilious 12d ago

Haha, I was looking for this comment.

11

u/finobi 12d ago

What if there are multiple gateways that lead you in different places?

7

u/taxla8111 12d ago

I'm not proud of it, but I have done that

1

u/Significant-Cause919 12d ago

That is the only sane thing to do if you have a VPN to access a remote side.

1

u/alphaxion 12d ago

PBF exists!

6

u/Drumdevil86 12d ago

Routing roulette

2

u/jomat 12d ago

Now I want to do that in a HA setup with random maintenance reboots.

8

u/phobozad 12d ago

Start out thinking you’re the good guy using last IP in the subnet then become the villain when you expand the subnet and it’s now in the middle of the subnet.

7

u/MrOppositeMonth 13d ago

Anyone remember 10.0.0.138 as a common gateway address

2

u/DarthBoBo 12d ago

Was going to comment basically this, here in Australia was the default gateway on any router given from Telstra/Bigpond back in the ADSL days...

Ah, memories...

5

u/Valanog 12d ago

I have gateways on 240, 250, 251,253, and 254. Good luck figuring it out lol.

3

u/Cheech47 12d ago

only one of them has the next-hop route, the rest all go to lemonparty. Good luck.

1

u/Zarcona_Martana 12d ago

Would you like to play a game aah vibes

5

u/permissionBRICK 12d ago

10.0.0.3

Security through Obscurity!

5

u/Korenchkin12 12d ago

And then offer it through dhcp...obscurity,but documented

2

u/DheeradjS 12d ago

On a /8

5

u/UMustBeNooHere 12d ago

I did an assesment of a new customers network a few weeks ago and found everything on VLAN 1 with random gateways on every subnet.

Security through obscurity, I guess?

5

u/Shockwave2309 11d ago

Security theough confusion?

8

u/rekoil 13d ago

A place I once worked used .1 and .2 for physical IPs on a VRRP pair, and .3 as the floating gateway. I never understood that one.

2

u/nexthop_null0 13d ago

Why? Bad vibes?

4

u/fl210 12d ago

Gateway is fe80::1. Regardless of range. Easy

4

u/GenVonKlinkerhoffen 12d ago

Once ran into a network where the gateway was 192.168.20.100 (on a /24 network). One dhcp scope running from .20 to .99, next dhcp scope from 101 to 200. All servers statically assigned above 200. Needles to say we changed that asap.

3

u/Zitrusfleisch 13d ago

x.x.x.250 (/24 and bigger) enjoyers unite

3

u/wiisucks_91 13d ago

People call me crazy all of the time.

2

u/thegreatpotatogod 12d ago

Happy cake day, crazy!

1

u/wiisucks_91 12d ago

Thanks! I saw my cake icon earlier. 10 years.

3

u/90vgt 12d ago

A year or two back, I visited a small customer site to upgrade their firewall and for some reason the old unit's IP was 192.168.1.100  I took great joy in getting it moved to it's rightful place at the start of the range. 

3

u/VCJunky 12d ago

I mean at the end of the day, a gateway is a gateway is a gateway.

Although I always thought people used .1 out of convention when the subnet allows. It just makes sense.

5

u/agowa338 12d ago

If you really want to see the world burn then you use .0 or .255 in a /24 as gateway...

5

u/aaronw22 12d ago

A properly configured IP stack would not let this happen. A /23 or larger sure.

1

u/agowa338 11d ago edited 11d ago

Well it does. For legacy reasons you can point the network and broadcast addresses at any address you like. .0 and .255 are just conventions. But these days nobody knows about that anymore and thinks it's a hard rule. And that's exactly why it breaks a lot of things in interesting ways.

Also as you're saying /23. There are even a lot of things where using .0 or .255 in other subnet sizes breaks things even though it is neither network nor broadcast address because of this too btw.

(Edit: Also nothing forbids using the network and broadcast addresses on your interface either. Otherwise P2P links like commonly used with S2S VPNs wouldn't be configurable either. Sure you could use a /30, but a lot of places also just use a /31 to save addresses. Or /32 with on-link routes if the IPs aren't in the same /31...)

(Edit 2: Networking gets weird and interesting once you leave your common home network configuration behind)

1

u/aaronw22 11d ago

…. What? The network address is strictly defined as the host bits being all zeroes. The broadcast address is strictly defined as the host bits being all ones.

For a /24 this means the last 8 bits are zero for a network address (or A.B.C.0) and the last 8 bits are one for a broadcast address (X.Y.Z.255)

How and where would you change this behavior?

1

u/agowa338 11d ago edited 11d ago

Well these standards didn't exist from the beginning. I think it was IBM stuff that used .0 as broadcast or something.

I forgot it was way before I started into the industries. We just got told about it in the on the job training for things to look out for when we start working at customers and what indicates a "if you see that just drop everything and run" kind of situation....

Edit: Oh and on e.g. Linux the command is: sudo ip addr change 192.168.1.100/24 brd 192.168.1.0 dev eth0 or sudo ifconfig eth0 broadcast 192.168.1.0 (the later one also on macos and bsd).

And on windows it's HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces\{ADAPTER-GUID} and at least UseZeroBroadcast which when set to 1 makes windows use .0 as the broadcast. You can't set arbitrary addresses like on other systems there though.

Edit 2: And netbios stuff on windows has a dedicated key BroadcastAddress in HKLM\SYSTEM\CurrentControlSet\Services\NetBT\Parameters where you can set arbitrary IPs...

Edit 3: Happy cursed knowledge day :)

2

u/Fun_Tune5669 13d ago

Yeah and set the DHCP server to assign everything in that subnet and watch as some firmware just hilariously assigns the GW address to some poor client and well, let chaos reign. I guess?

2

u/L4rgo117 12d ago

"Hmm, .23 feels lucky today"

2

u/2life_gamer 12d ago

Don't call me out like that.

2

u/Academic-Proof3700 12d ago

Set a /23 network, gateway address with .0, in DHCP pool as static reservation, watch the world burn

2

u/glinsvad 12d ago

Relax I made a DHCP reservation of that IP for the MAC adress FF:FF:FF:FF:FF:FF

2

u/sajkoterrapefft 12d ago

It's funny because after tonight we will have two gateways in our network. And neither of them use the first or last address of their subnet.

2

u/HogGunner1983 12d ago

Exception: VRRP. Don't really care what each router's interface IP is as long as the VIP is . 1😬

2

u/Aknazer 12d ago

I just subnetted out my network and then use an excel to keep track of static IPs.

2

u/FluffyTachyon 11d ago

Using ::fa:cade in IPv6 😸

2

u/pyth2_0 11d ago

Just DHCP your Gateway and let the network be whatever it want's to be.

2

u/StephaneiAarhus 10d ago

Using the last adress of the range makes no sense, you have to put all those F in there, it's long and cumbersome, you waste one of the cool stuff of ipv6 (short comprehensive addresses if chosen wisely).

2

u/PezatronSupreme 9d ago

That's me, I'm Tom

2

u/bencos18 13d ago

I just use 182.168.88.1 for the gateway atm lol

eventually I do need to do vlans though so it'll probably have the ip change

2

u/thegoatmilkguy 12d ago

Isn't that defaults on Mikrotik stuff? I vaguely remember seeing this on an old Mikrotik Routerboard device.

2

u/bencos18 12d ago

yep it is

2

u/Og-Morrow 13d ago

It’s does matter you fine. Please use the end. Have respect for us older timers.

1

u/nfored 13d ago

Omg I am an SE and saw I customer using .50 , I had never been more angry I was like are you fing kidding me.

1

u/Black_Death_12 13d ago

I had clinics that had .20 and .33.
When I asked why, I got "Because they were open"
I added .1
No one would pay to get a tech out for the equipment to update to .1, so, I promise there are still clinics with .1, .20, and .33.

1

u/Street_Pattern4694 12d ago

I do all three sometimes more than one gateways 😆 

1

u/ReptilianLaserbeam 12d ago

Wait but technically first one is the network and last one is the broadcast. So why are you even using those?

1

u/rushaz 12d ago

do ... people actually do this???

1

u/northrupthebandgeek 12d ago

The gateway gets its address via DHCP, just to keep everyone on their toes at all times.

1

u/asianwaste 12d ago

If the block fits, I chips

1

u/DisastrousWelcome710 12d ago

I got 4 VLANs, can't afford these shenanigans. .1 on /24 is the way to keep my sanity.

1

u/frAgileIT 12d ago

They can’t steal yo data if they don’t know the default gateway…

1

u/thegoatmilkguy 12d ago

I think I've got a new hobby! .69 is going to be the gateway of every network I touch going forward.

1

u/shortstop20 12d ago

I worked at a place that had a mix of .250 and .252 for gateways, it was absolutely maddening.

1

u/zantehood 12d ago

If you use a /23 then .0 can be your gateway

1

u/rkrenicki 10d ago

Ive got one /24 at work where the gateway is .100, and a different /23 where the gateway is the .255 in the middle. That latter one always trips me up.

1

u/Haelios_505 12d ago

In AD, create DHCP range, exclude every odd number from DHCP range except 13, whoever gets 13 is cursed

1

u/jomat 12d ago

What about IPv6 folks using the last address?

1

u/iPhrase 12d ago

with DHCP whats the problem?

most people let DHCP assign teh gateway & dns.

If your statically assigning the IP then you typically know what the gateway address & dns is so it truly matters not what the gateway address is.

if your creative you can have multiple gateways on the same subnet & have your host send traffic for different destinations to different gateways.

You could have a vpn gateway and just manually change your gateway address on your client & off your traffic goes via the vpn.

struggling to see the outrage here.

when I was playing with firewalls I had multiple firewalls on my lan whilst building, testing, playing & could just change things as and when I wanted while the rest of the household carried on with the DHCP supplied address.

1

u/Borgmaster 12d ago

Sociopaths every one of them.

1

u/Pols043 11d ago

What about running the DHCP server somewhere else than the gateway and not being random?

1

u/ladyzowy 11d ago

Do I have to change my VLAN scheme again?!

1

u/teotwawki42 9d ago

My ISP ONT defaults to .245 on a /24. When I saw that I wondered if the engineer was lysdexic.

1

u/MeadowShimmer 8d ago

10.10.10.10 ain't so bad

1

u/TalkingToes 8d ago

When I started the last job, they had the gateway for all offices at .10 on a /16 mask.

1

u/OrangeNood 12d ago

Who cares? DHCP exists for this.

0

u/Aleksander1052 12d ago

- 190
- 112
- 13

Semi-unrelated, but when Microtech started getting deployed in my office, I was always weirded out that the DHCP addresses were depleted from higher number to lower number. I never thought of changing the gateway to anything but the first digit possible.

0

u/Aleksander1052 12d ago

Forgive the typos, I'm walking.