找回密码
 快速注册
搜索
查看: 39|回复: 2

[Firefox]Convert an Integer to an IP Address

[复制链接]

3149

主题

8386

回帖

6万

积分

$\style{scale:11;fill:#eff}꩜$

积分
65391
QQ

显示全部楼层

hbghlyj 发表于 2022-9-13 21:26 |阅读模式
Convert decimal to base 256

7⇒0.0.0.7 Screenshot 2022-09-12 at 20-02-35 word里的单引号【’】与【'】 分别怎么打?_.png
77⇒0.0.0.77 Screenshot 2022-09-12 at 20-02-35 word里的单引号【’】与【'】 分别怎么打?_.png
770⇒0.0.3.2
770=3*256+2
Screenshot 2022-09-12 at 20-02-35 word里的单引号【’】与【'】 分别怎么打?_.png
770975⇒0.11.195.159 Screenshot 2022-09-12 at 20-02-35 word里的单引号【’】与【'】 分别怎么打?_.png
7709756⇒0.117.164.60 Screenshot 2022-09-12 at 20-02-35 word里的单引号【’】与【'】 分别怎么打?_.png

3149

主题

8386

回帖

6万

积分

$\style{scale:11;fill:#eff}꩜$

积分
65391
QQ

显示全部楼层

 楼主| hbghlyj 发表于 2022-9-13 23:37
superuser.com/questions/736583
The last 32-bits of the number are 3660944368 (in decimal, which can be found by 714687644714805209715128610715964400 mod 2^32)

This is the decimal value of the IPv4 address 218.53.147.240, which can be found by converting it to base-256 3660944368 = 218*(256^3)+53*(256^2)+147*(256)+240 analogous to writing out a number in decimal (base-10). For example 234 = 2*10^2+ 3*10 + 4.

bugzilla.mozilla.org/show_bug.cgi?id=67730
I don't think we should block these urls.  It's much easier for me to remember
2259499800 than it is for me to remember 134.173.59.24, and it isn't much more
obfuscated.

connect.mozilla.org/t5/discussions/converting-ip-in-address-bar-from-decimal-numbers/td-p/10123
Simple question about the address bar in Firefox 102.0.1.

I discovered today that you can convert bytes into IP addresses by typing for example "2130706433/", which will result in the address being resolved to "127.0.0.1". Is this an intended feature or unintended behavior? Thanks.

3149

主题

8386

回帖

6万

积分

$\style{scale:11;fill:#eff}꩜$

积分
65391
QQ

显示全部楼层

 楼主| hbghlyj 发表于 2022-9-13 23:45
Integer:
3105589147/                   (The link also works for Chrome)
Equivalent to IPv4:
185.27.135.155/
Resolve to domain name:
cjhb.site/

手机版|悠闲数学娱乐论坛(第3版)

GMT+8, 2025-3-4 15:28

Powered by Discuz!

× 快速回复 返回顶部 返回列表