Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/python-3.x/15.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
用Python授权路由器面板_Python_Python 3.x_Authorization_Router - Fatal编程技术网

用Python授权路由器面板

用Python授权路由器面板,python,python-3.x,authorization,router,Python,Python 3.x,Authorization,Router,我试图使用python登录路由器的面板,但问题是我不知道这样做的协议是什么。我尝试使用Wireshark来找出答案,但它只显示一个GET请求和一个响应。我尝试登录到路由器,然后在数据包中搜索用户名和密码,但它没有找到。(我猜是加密的) 如果有人能帮助我了解登录面板的协议,我将不胜感激。找到了。FLOWING TCP流为我提供了以下信息: GET / HTTP/1.1 Host: 10.0.0.138 Connection: keep-alive Cache-Control: max-age=0

我试图使用python登录路由器的面板,但问题是我不知道这样做的协议是什么。我尝试使用Wireshark来找出答案,但它只显示一个GET请求和一个响应。我尝试登录到路由器,然后在数据包中搜索用户名和密码,但它没有找到。(我猜是加密的)


如果有人能帮助我了解登录面板的协议,我将不胜感激。

找到了。FLOWING TCP流为我提供了以下信息:

GET / HTTP/1.1
Host: 10.0.0.138
Connection: keep-alive
Cache-Control: max-age=0
Authorization: Basic UG90YXRvOg==
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36
Accept-Encoding: gzip, deflate, sdch
Accept-Language: en-US,en;q=0.8,he;q=0.6

HTTP/1.0 401 Unauthorized
WWW-Authenticate: Basic realm="NETGEAR DGN2200v2BEZEQ"
Content-type: text/html

<html>
<head><title>401 Unauthorized</title></head>
<body><h1>401 Unauthorized</h1>
<p>Access to this resource is denied, your client has not supplied the correct authentication.</p></body>
</html>
GET/HTTP/1.1
主持人:10.0.0.138
连接:保持活力
缓存控制:最大年龄=0
授权:基本UG90YXRvOg==
接受:text/html、application/xhtml+xml、application/xml;q=0.9,图像/webp,*/*;q=0.8
升级不安全的请求:1
用户代理:Mozilla/5.0(Windows NT 6.3;WOW64)AppleWebKit/537.36(KHTML,如Gecko)Chrome/49.0.2623.112 Safari/537.36
接受编码:gzip、deflate、sdch
接受语言:en-US,en;q=0.8,他;q=0.6
HTTP/1.0 401未经授权
WWW-Authenticate:Basic realm=“NETGEAR DGN2200v2BEZEQ”
内容类型:text/html
401未经授权
401未经授权
对此资源的访问被拒绝,您的客户端未提供正确的身份验证

用户名和密码以
username:password
的格式编码在
base64