# coding=utf-8
import socket
def get_plugin_info():
plugin_info = {
"name": "Zookeeper未授权访问",
"info": "Zookeeper Unauthorized access",
"level": "中危",
"type": "未授权访问"
"keyword": "server:Zookeeper",
"source": 1
}
return plugin_info
def check(ip, port, timeout):
try:
socket.setdefaulttimeout(timeout)
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect((ip, int(port)))
flag = "envi"
s.send(flag)
data = s.recv(1024)
s.close()
if 'Environment' in data:
return u"Zookeeper Unauthorized access"
except:
pass
def main():
ip = "xxxx"
print check(ip, 2181, 2)
if __name__ == '__main__':
main()
zooker未授权访问脚本
最新推荐文章于 2024-10-04 14:48:46 发布