海运的博客

全球各国家IP/ASN及BGP路由信息

发布时间:January 20, 2015 // 分类: // No Comments

全球IP/ASN由ICANN负责分配和管理,ICANN将部分IP地址分配给地区级的Internet注册机构 (RIR),然后由这些RIR负责该地区的登记注册服务。
全球一共有5个RIR,其分配的IP信息如下:
北美地区
ftp://ftp.arin.net/pub/stats/arin/delegated-arin-extended-latest
欧洲地区
ftp://ftp.ripe.net/ripe/stats/delegated-ripencc-latest
非洲地区
ftp://ftp.afrinic.net/pub/stats/afrinic/delegated-afrinic-latest
亚太地区
ftp://ftp.apnic.net/pub/stats/apnic/delegated-apnic-latest
拉丁美洲
ftp://ftp.lacnic.net/pub/stats/lacnic/delegated-lacnic-latest
ISO国家标准码:
http://www.iso.org/iso/home/standards/country_codes/country_names_and_code_elements_txt-temp.htm
全球BGP路由表信息:
http://routeviews.org/
http://bgp.potaroo.net/index-bgp.html
可telnet的主干网路由,查询全球路由表:
route-server.ip.att.net
route-views.routeviews.org

此内容被密码保护

发布时间:January 17, 2015 // 分类: // No Comments

请输入密码访问

PHP调用淘宝API获取用户IP信息

发布时间:November 4, 2013 // 分类:PHP // No Comments

<?php
header('Content-Type:text/html;charset=utf-8');
$ip = $_SERVER["REMOTE_ADDR"];
$ch = curl_init(); 
curl_setopt($ch, CURLOPT_URL, "http://ip.taobao.com/service/getIpInfo.php?ip=$ip");
curl_setopt($ch, CURLOPT_REFERER, "http://www.test.com");
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.1) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11");
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT,3);
curl_setopt($ch,CURLOPT_TIMEOUT,3);
curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);
$ipinfo=json_decode(curl_exec($ch),1);
echo $ipinfo[data][region].$ipinfo[data][city].$ipinfo[data][isp];
?>

Linux添加不同网段多IP脚本

发布时间:June 16, 2013 // 分类:Shell // No Comments

将要添加的零散IP保存到文件,判断IP网段添加IP时设定相应的掩码。

#!/bin/bash
for ip in `cat ip.txt`
do
    if [[ $ip =~ ^184.164.141 ]]
    then
        ip add add $ip/26 dev eth0
    else
        ip add add $ip/27 dev eth0
    fi
done

ROS静态绑定ARP-IP

发布时间:February 12, 2013 // 分类:ROS // No Comments

ROS静态绑定ARP与IP:

ip arp add interface=Wan address=192.168.1.232 mac-address=90:2B:34:AF:A2:EC 

将当前动态ARP绑定为静态ARP:
ROS绑定静态ARP.png
Linux/Windows客户端静态ARP绑定见:https://www.haiyun.me/archives/linux-windows-static-arp.html

分类
最新文章
最近回复
  • 海运: 恩山有很多。
  • swsend: 大佬可以分享一下固件吗,谢谢。
  • Jimmy: 方法一 nghtp3步骤需要改成如下才能编译成功: git clone https://git...
  • 海运: 地址格式和udpxy一样,udpxy和msd_lite能用这个就能用。
  • 1: 怎么用 编译后的程序在家里路由器内任意一台设备上运行就可以吗?比如笔记本电脑 m参数是笔记本的...
  • 孤狼: ups_status_set: seems that UPS [BK650M2-CH] is ...
  • 孤狼: 擦。。。。apcupsd会失联 nut在冲到到100的时候会ONBATT进入关机状态,我想想办...
  • 海运: 网络,找到相应的url编辑重发请求,firefox有此功能,其它未知。
  • knetxp: 用浏览器F12网络拦截或监听后编辑重发请求,修改url中的set为set_super,将POS...
  • Albert: 啊啊啊啊啊啊啊啊啊 我太激动了,终于好了英文区搜索了半天,翻遍了 pve 论坛没找到好方法,博...