fastfetch
fastfetch copied to clipboard
[FEAT] Forcing IPv6 in output by default
Wanted features:
At the moment, doing a fastfetch command i've get only my IPv4 address with a subnet.
I think it is little wrong, IPv6 must be preferred as in all services.
So I suggest to change network output:
IPv6 GUA on interface (if it exist 2000::/3)
IPv6 ULA on interface (if it exist fc00::/7)
and after that IPv4 address.
and making a flag for link-local(fe80::/10) like --localip-show-link-local
Motivation:
IPv4 actual protocol, but it gonna be old in future, we should force IPv6 output everywhere for next generation of engineers.
IPv6 GUA on interface (if it exist
2000::/3) IPv6 ULA on interface (if it existfc00::/8)
Doesn't it leak your public ip address?
IPv6 GUA on interface (if it exist
2000::/3) IPv6 ULA on interface (if it existfc00::/8)Doesn't it leak your public ip address?
- Is it really somebody cares, especially if we show address by rfc8981
- "Leaking" isn't security issue, it's just an address.
- If i launch fastfetch now at my server, it shows me my "white" ipv4 address. Same thing.
I really read FAQ and as network engineer, I truly don't understand the problem of "leaking" IP. But if people want to hide their IP, we could make a flag which hide IP or replace some octets/hextets to :XXXX: / .xxx.
If you want to show IPv6, you can set the config
{
"type": "localip",
"showAllIps": true,
"showIpv6": true,
"format": "{ipv6} [v6] {ipv4} [v4]"
}
Sorting is not supported though.
If you want to show IPv6, you can set the config
{ "type": "localip", "showAllIps": true, "showIpv6": true, "format": "{ipv6} [v6] {ipv4} [v4]" }
Sorting is not supported though.
OFFTOPIC!
If somebody trying to hack by its IP it isn't problem of fastfetch, it is OS/Software problem, and it will happen anyway, with fastfetch or not. Moreover you are the maintainer of this repo, and if you want to show IP, who cares? Showing IPv6 really safe, like with IPv4. And IPv6 anyway will change if it be given by RA."It should not require secrecy, and it should not be a problem if it falls into enemy hands;" you know...
Anyway I think it's better to consider to devide pools of addresses by ULA, GUA, link-locals, because in IPv6 having few addresses on the interface is a normal thing.
Hi all,
Check out how archey4 implements it — it should be considered the best practice in my view.
They break it out into LAN IP and WAN IP and show local IPv4 and IPv6 ULA for the first one and external IPv4 and IPv6 GUA for the second one.
On "leaking" IP:
- Internal IPv4 and IPv6 ULA are internal and not accessible from the outside world — so, who cares?
- External IPv4 and IPv6 GUA are dynamic for most people (on residential internet). Correctly configured host uses privacy extensions for IPv6 (so, even if prefix is fixed, the suffix is dynamic). And as for fixed external IPv4 — NAT is not security — your firewall is. If exposing your external IPv4 poses a security risk for you, you are doing something wrong in this life :))))
They break it out into LAN IP and WAN IP
Fastfetch calls WAN IP as Public IP. You can enable it in your config file.
Local IP should have been called Network, as they are not necessarily local IPs. If you run fastfetch in your public server, you will get public IPs.
Internal IPv4 and IPv6 ULA are internal and not accessible from the outside world — so, who cares?
Who doesn't know IPv4 and IPv6 ULA are internal and not accessible from the outside world care.
BTW, I never saw a ULA except in virtual machines. Not sure how you get that. I always get ULAs on both my PC (connect to a router) and my cell phone (connect to ISP directly)
External IPv4 and IPv6 GUA are dynamic for most people (on residential internet). Correctly configured host uses privacy extensions for IPv6 (so, even if prefix is fixed, the suffix is dynamic). And as for fixed external IPv4 — NAT is not security — your firewall is. If exposing your external IPv4 poses a security risk for you, you are doing something wrong in this life :))))
At least it leaks your location (Germany?). Even if you don't care, there are people care.
@CarterLi, thanks for looking into this! It would be great to have control over which IPv6 exactly to output (Link local, GUA, ULA, EUI-64, etc) in fastfetch. And also to be able to output both, public IPv4 and IPv6 in one line (i.e. to have {ipv4} and {ipv6} in "type": "publicip".
I messed around with it and and the closest I got is this:
{
"type": "localip",
"key": "Local IP ({ifname})",
"showPrefixLen": true,
"showIpv4": true,
"showIpv6": true,
"showMtu": true,
"format": "{ipv4}, {ipv6}"
},
{
"type": "publicip",
"key": "Public IPv4",
"ipv6": false,
"format": "{ip} {#2}[{location}]"
},
{
"type": "publicip",
"key": "Public IPv6",
"ipv6": true,
"format": "{ip} {#2}[{location}]"
},
On ULA: I use it in my home network to route traffic between local devices and home servers via IPv6 (because I have a dynamic IPv6 prefix which is quite common).
IPv6 type selection support was added.
{
"type": "localip",
"showIpv6": "ula", // Show ULA only
}
However, IPv6 addresses will still not be enabled by default