诺甘农圆盘

参考资料收集库

用户工具

站点工具


小米路由器_r2d:手机端管理端口

小米路由器R2D的手机端管理端口

今天大概看了一下小米路由器的手机端管理机制。

依靠以下这个服务运行,在小米服务器端登记注册,然后手机端通过小米服务器作为中介跟路由器交互管理。

#/etc/init.d/messagingagent.sh
root@XiaoQiang:/etc/init.d# cat messagingagent.sh
#!/bin/sh /etc/rc.common

START=49
#STOP=50

num='2'

config_load misc
config_get num messagingagent thread_num

#export command line for /usr/sbin/supervisord
export PROCLINE="nice -n -5 /usr/bin/messagingagent --handler_threads $num"
export PROCFLAG="/usr/bin/messagingagent --handler_threads $num"
export PROC_DEBUG_FLAG="on"
export OOM_FLAG=0

export EXTRA_HELP="     status  Status the service"
export EXTRA_COMMANDS="status"

stop() {
        /usr/sbin/supervisord stop
        return $?
}
start() {
        /usr/sbin/supervisord start
        return $?
}
restart() {
        stop
        sleep 1
        start
        return $?
}
shutdown() {
        stop
        return $?
}
status() {
        /usr/sbin/supervisord status
        return $?
}

其中提到调用以下服务/usr/bin/messagingagent

  • export PROCLINE=“nice -n -5 /usr/bin/messagingagent –handler_threads $num”
  • export PROCFLAG=“/usr/bin/messagingagent –handler_threads $num”

这个服务的说明如下:

  • 配置文件位于/usr/share/messaging/messaging.conf
root@XiaoQiang:/etc/init.d# /usr/bin/messagingagent --help
Messaging agent
Usage: MessagingAgent [--host host] [--port port] [--config path]
  --host: host name of MQTT broker (default: localhost)
  --port: port number (default: 1883)
  --config: path to config file (default: /usr/share/messaging/messaging.conf)
  --handler_threads: number of message handler threads (default: 6)
  --help: print usage information

所以打开这个配置文件看看:

root@XiaoQiang:/etc/init.d# cat /usr/share/messaging/messaging.conf
key_file = /usr/share/messaging/serverkey.pub
push_channel = xqpc
config_url = http://api.miwifi.com/config
register_device_url = http://api.miwifi.com/register_device
miwifi_service_ips = 223.202.68.59:42.62.48.82

里面标明了2个IP地址,分别为

  • 223.202.68.59
  • 42.62.48.82

再看看这2个IP是谁家的

-----------------------------------------------
Source: whois.apnic.netIP Address: 223.202.68.59
% [whois.apnic.net]
% Whois data copyright terms    http://www.apnic.net/db/dbcopyright.html

% Information related to '223.202.68.0 - 223.202.71.255'

% Abuse contact for '223.202.68.0 - 223.202.71.255' is 'ipas@cnnic.cn'

inetnum:        223.202.68.0 - 223.202.71.255
netname:        CHINACACHE
descr:          Beijing Blue I.T Technologies Co.,Ltd.
descr:          Galaxy Building,No.10 jiuxianqiao ,chaoyang
descr:          District,beijing
country:        CN
admin-c:        YS1150-AP
tech-c:         DC1032-AP
mnt-by:         MAINT-CNNIC-AP
mnt-lower:      MAINT-CNNIC-AP
mnt-irt:        IRT-CNNIC-CN
mnt-routes:     maint-cn-cstnet
status:         Assigned NON-PORTABLE
last-modified:  2012-03-09T06:20:02Z
source:         APNIC

irt:            IRT-CNNIC-CN
address:        Beijing, China
e-mail:         ipas@cnnic.cn
abuse-mailbox:  ipas@cnnic.cn
admin-c:        IP50-AP
tech-c:         IP50-AP
auth:           # Filtered
remarks:        Please note that CNNIC is not an ISP and is not
remarks:        empowered to investigate complaints of network abuse.
remarks:        Please contact the tech-c or admin-c of the network.
mnt-by:         MAINT-CNNIC-AP
last-modified:  2017-11-01T08:57:39Z
source:         APNIC

person:         Dong Cheng
nic-hdl:        DC1032-AP
e-mail:         adam.cheng@chinacache.com
address:        Galaxy Building,No.10 jiuxianqiao ,chaoyang District,beijing
phone:          +86-010-64373399-805
fax-no:         +86-010-64374251
country:        CN
mnt-by:         MAINT-CNNIC-AP
last-modified:  2008-12-31T04:05:33Z
source:         APNIC

person:         Yalin Shu
nic-hdl:        YS1150-AP
e-mail:         yao.fu@chinacache.co
address:        Galaxy Building,No.10 jiuxianqiao ,chaoyang District,beijing
phone:          +86-010-64373399-262
fax-no:         +86-010-64374251
country:        CN
mnt-by:         MAINT-CNNIC-AP
last-modified:  2015-03-16T02:38:31Z
source:         APNIC

% Information related to '223.202.68.0/22AS37958'

route:          223.202.68.0/22
descr:          Beijing Blue I.T Technologies Co.,Ltd.
country:        CN
origin:         AS37958
remarks:        Please contact  xinpeng.liu@chinacache.com if you have any
remarks:        Questions regarding this object.
notify:         xinpeng.liu@chinacache.com
mnt-by:         MAINT-CNNIC-AP
last-modified:  2012-04-12T05:56:02Z
source:         APNIC

% This query was served by the APNIC Whois Service version 1.88.15-46 (WHOIS-US3)
-----------------------------------------------------------
Source: whois.apnic.netIP Address: 42.62.48.82
% [whois.apnic.net]
% Whois data copyright terms    http://www.apnic.net/db/dbcopyright.html

% Information related to '42.62.0.0 - 42.62.127.255'

% Abuse contact for '42.62.0.0 - 42.62.127.255' is 'ipas@cnnic.cn'

inetnum:        42.62.0.0 - 42.62.127.255
netname:        Forest-Eternal
descr:          Forest Eternal Communication Tech. co.ltd
descr:          Rm.902,North Real Estate Building, Build. No.3,
descr:          #81Yuan,Haidian District,Beijing
country:        CN
admin-c:        HL2233-AP
tech-c:         GT483-AP
status:         ALLOCATED PORTABLE
mnt-by:         MAINT-CNNIC-AP
mnt-lower:      MAINT-CNNIC-AP
mnt-routes:     MAINT-CNNIC-AP
mnt-irt:        IRT-CNNIC-CN
last-modified:  2012-08-27T02:48:01Z
source:         APNIC

irt:            IRT-CNNIC-CN
address:        Beijing, China
e-mail:         ipas@cnnic.cn
abuse-mailbox:  ipas@cnnic.cn
admin-c:        IP50-AP
tech-c:         IP50-AP
auth:           # Filtered
remarks:        Please note that CNNIC is not an ISP and is not
remarks:        empowered to investigate complaints of network abuse.
remarks:        Please contact the tech-c or admin-c of the network.
mnt-by:         MAINT-CNNIC-AP
last-modified:  2017-11-01T08:57:39Z
source:         APNIC

person:         Guo Tao
address:        Rm.902,North Real Estate Building, Build. No.3,
address:        #81Yuan,Haidian District,Beijing
country:        CN
phone:          +86-010-51659311
e-mail:         gt@lenet.com.cn
nic-hdl:        GT483-AP
mnt-by:         MAINT-CNNIC-AP
last-modified:  2011-06-28T07:54:02Z
source:         APNIC

person:         Hong Lei
address:        Rm.902,North Real Estate Building, Build. No.3,
address:        #81Yuan,Haidian District,Beijing
country:        CN
phone:          +86-18901136688
e-mail:         695105546@qq.com
nic-hdl:        HL2233-AP
mnt-by:         MAINT-CNNIC-AP
last-modified:  2017-04-26T05:28:42Z
source:         APNIC

% This query was served by the APNIC Whois Service version 1.88.15-46 (WHOIS-US3)

里面分别有xinpeng.liu@chinacache.com和gt@lenet.com.cn两家公司的邮箱,上网看看了都是数据平台CDN中间商,就就没啥意思再看下去了。 *蓝汛ChinaCache #http://www.chinacache.com *北京森华易腾通信技术有限公司 #http://www.lenet.com.cn

小米路由器_r2d/手机端管理端口.txt · 最后更改: 2019/09/30 21:48 由 127.0.0.1