From 1e4ec64650b439e7ed3b4302f92db9603cb1fa30 Mon Sep 17 00:00:00 2001 From: Justin Bastress Date: Fri, 4 May 2018 11:15:09 -0400 Subject: [PATCH] schemas.zgrab2 -> zgrab2_schemas --- setup.py | 8 ++------ {schemas => zgrab2_schemas}/README.md | 0 {schemas => zgrab2_schemas}/__init__.py | 0 {schemas => zgrab2_schemas}/zgrab2/__init__.py | 0 {schemas => zgrab2_schemas}/zgrab2/bacnet.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/dnp3.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/fox.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/ftp.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/http.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/imap.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/modbus.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/mssql.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/mysql.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/ntp.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/oracle.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/pop3.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/postgres.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/redis.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/siemens.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/smb.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/smtp.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/ssh.py | 2 +- {schemas => zgrab2_schemas}/zgrab2/telnet.py | 2 +- .../zgrab2/testdata/ftp-authtls.json | 0 .../zgrab2/testdata/ftp-default.json | 0 .../zgrab2/testdata/http-http.json | 0 .../zgrab2/testdata/http-https.json | 0 .../zgrab2/testdata/mssql-2017-linux.json | 0 .../zgrab2/testdata/mysql-5.5.json | 0 .../zgrab2/testdata/mysql-5.6.json | 0 .../zgrab2/testdata/mysql-5.7.json | 0 .../zgrab2/testdata/mysql-8.0.json | 0 .../zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST.json | 0 .../zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1.json | 0 .../zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1_solo.json | 0 .../zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_solo.json | 0 .../zgrab2/testdata/ntp-4.2.6_monlist.json | 0 .../zgrab2/testdata/ntp-4.2.6_normal.json | 0 .../zgrab2/testdata/ntp-openntp.json | 0 .../zgrab2/testdata/pop3-banner.json | 0 .../zgrab2/testdata/pop3-banner.quit.json | 0 .../zgrab2/testdata/pop3-help.banner.quit.json | 0 .../zgrab2/testdata/pop3-noop.help.banner.quit.json | 0 .../zgrab2/testdata/postgres-10.1-nossl.json | 0 .../zgrab2/testdata/postgres-10.1-ssl.json | 0 .../zgrab2/testdata/postgres-9.3-nossl.json | 0 .../zgrab2/testdata/postgres-9.3-ssl.json | 0 .../zgrab2/testdata/postgres-9.4-nossl.json | 0 .../zgrab2/testdata/postgres-9.4-ssl.json | 0 .../zgrab2/testdata/postgres-9.5-nossl.json | 0 .../zgrab2/testdata/postgres-9.5-ssl.json | 0 .../zgrab2/testdata/postgres-9.6-nossl.json | 0 .../zgrab2/testdata/postgres-9.6-ssl.json | 0 .../zgrab2/testdata/redis-default-inline.json | 0 .../zgrab2/testdata/redis-default-normal.json | 0 .../zgrab2/testdata/redis-password-inline.json | 0 .../zgrab2/testdata/redis-password-normal.json | 0 .../zgrab2/testdata/redis-renamed-inline.json | 0 .../zgrab2/testdata/redis-renamed-normal.json | 0 {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-00.json | 0 .../zgrab2/testdata/smtp-ehlo.03.json | 0 .../zgrab2/testdata/smtp-ehlo.04.json | 0 .../zgrab2/testdata/smtp-ehlo.quit.05.json | 0 .../zgrab2/testdata/smtp-helo.01.json | 0 .../zgrab2/testdata/smtp-helo.02.json | 0 .../zgrab2/testdata/smtp-help.quit.06.json | 0 {schemas => zgrab2_schemas}/zgrab2/testdata/ssh-ssh.json | 0 .../zgrab2/testdata/telnet-telnet.json | 0 {schemas => zgrab2_schemas}/zgrab2/tests.py | 0 {schemas => zgrab2_schemas}/zgrab2/zgrab2.py | 2 +- 70 files changed, 22 insertions(+), 26 deletions(-) rename {schemas => zgrab2_schemas}/README.md (100%) rename {schemas => zgrab2_schemas}/__init__.py (100%) rename {schemas => zgrab2_schemas}/zgrab2/__init__.py (100%) rename {schemas => zgrab2_schemas}/zgrab2/bacnet.py (97%) rename {schemas => zgrab2_schemas}/zgrab2/dnp3.py (92%) rename {schemas => zgrab2_schemas}/zgrab2/fox.py (96%) rename {schemas => zgrab2_schemas}/zgrab2/ftp.py (93%) rename {schemas => zgrab2_schemas}/zgrab2/http.py (98%) rename {schemas => zgrab2_schemas}/zgrab2/imap.py (94%) rename {schemas => zgrab2_schemas}/zgrab2/modbus.py (97%) rename {schemas => zgrab2_schemas}/zgrab2/mssql.py (96%) rename {schemas => zgrab2_schemas}/zgrab2/mysql.py (98%) rename {schemas => zgrab2_schemas}/zgrab2/ntp.py (97%) rename {schemas => zgrab2_schemas}/zgrab2/oracle.py (99%) rename {schemas => zgrab2_schemas}/zgrab2/pop3.py (95%) rename {schemas => zgrab2_schemas}/zgrab2/postgres.py (98%) rename {schemas => zgrab2_schemas}/zgrab2/redis.py (97%) rename {schemas => zgrab2_schemas}/zgrab2/siemens.py (95%) rename {schemas => zgrab2_schemas}/zgrab2/smb.py (97%) rename {schemas => zgrab2_schemas}/zgrab2/smtp.py (93%) rename {schemas => zgrab2_schemas}/zgrab2/ssh.py (99%) rename {schemas => zgrab2_schemas}/zgrab2/telnet.py (94%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ftp-authtls.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ftp-default.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/http-http.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/http-https.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/mssql-2017-linux.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/mysql-5.5.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/mysql-5.6.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/mysql-5.7.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/mysql-8.0.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1_solo.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_solo.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-4.2.6_monlist.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-4.2.6_normal.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ntp-openntp.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/pop3-banner.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/pop3-banner.quit.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/pop3-help.banner.quit.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/pop3-noop.help.banner.quit.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-10.1-nossl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-10.1-ssl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.3-nossl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.3-ssl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.4-nossl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.4-ssl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.5-nossl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.5-ssl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.6-nossl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/postgres-9.6-ssl.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/redis-default-inline.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/redis-default-normal.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/redis-password-inline.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/redis-password-normal.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/redis-renamed-inline.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/redis-renamed-normal.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-00.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-ehlo.03.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-ehlo.04.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-ehlo.quit.05.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-helo.01.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-helo.02.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/smtp-help.quit.06.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/ssh-ssh.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/testdata/telnet-telnet.json (100%) rename {schemas => zgrab2_schemas}/zgrab2/tests.py (100%) rename {schemas => zgrab2_schemas}/zgrab2/zgrab2.py (98%) diff --git a/setup.py b/setup.py index cf7cb95..578560c 100644 --- a/setup.py +++ b/setup.py @@ -4,7 +4,7 @@ from setuptools import setup, find_packages here = os.path.abspath(os.path.dirname(__file__)) setup( - name="zgrab2-schemas", + name="zgrab2_schemas", version="0.0.1", description="ZSchema definitions for zgrab2's JSON output.", classifiers=[ @@ -15,11 +15,7 @@ setup( author_email="team@zmap.io", url="https://github.com/zmap/zgrab2", keywords="zmap censys zgrab2 internet-wide scanning", - # packages=["schemas/zgrab2"], packages=find_packages(), include_package_data=True, - zip_safe=False, - install_requires = [ - "zschema" - ], + zip_safe=False ) diff --git a/schemas/README.md b/zgrab2_schemas/README.md similarity index 100% rename from schemas/README.md rename to zgrab2_schemas/README.md diff --git a/schemas/__init__.py b/zgrab2_schemas/__init__.py similarity index 100% rename from schemas/__init__.py rename to zgrab2_schemas/__init__.py diff --git a/schemas/zgrab2/__init__.py b/zgrab2_schemas/zgrab2/__init__.py similarity index 100% rename from schemas/zgrab2/__init__.py rename to zgrab2_schemas/zgrab2/__init__.py diff --git a/schemas/zgrab2/bacnet.py b/zgrab2_schemas/zgrab2/bacnet.py similarity index 97% rename from schemas/zgrab2/bacnet.py rename to zgrab2_schemas/zgrab2/bacnet.py index f2a7339..20d998b 100644 --- a/schemas/zgrab2/bacnet.py +++ b/zgrab2_schemas/zgrab2/bacnet.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas import zgrab2 bacnet_scan_response = SubRecord({ diff --git a/schemas/zgrab2/dnp3.py b/zgrab2_schemas/zgrab2/dnp3.py similarity index 92% rename from schemas/zgrab2/dnp3.py rename to zgrab2_schemas/zgrab2/dnp3.py index c8fb1db..f8e297a 100644 --- a/schemas/zgrab2/dnp3.py +++ b/zgrab2_schemas/zgrab2/dnp3.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 dnp3_scan_response = SubRecord({ diff --git a/schemas/zgrab2/fox.py b/zgrab2_schemas/zgrab2/fox.py similarity index 96% rename from schemas/zgrab2/fox.py rename to zgrab2_schemas/zgrab2/fox.py index 7fc27f4..c1325f9 100644 --- a/schemas/zgrab2/fox.py +++ b/zgrab2_schemas/zgrab2/fox.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 fox_scan_response = SubRecord({ diff --git a/schemas/zgrab2/ftp.py b/zgrab2_schemas/zgrab2/ftp.py similarity index 93% rename from schemas/zgrab2/ftp.py rename to zgrab2_schemas/zgrab2/ftp.py index 2b2aec2..b9e3c8b 100644 --- a/schemas/zgrab2/ftp.py +++ b/zgrab2_schemas/zgrab2/ftp.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 # modules/ftp.go - FTPScanResults diff --git a/schemas/zgrab2/http.py b/zgrab2_schemas/zgrab2/http.py similarity index 98% rename from schemas/zgrab2/http.py rename to zgrab2_schemas/zgrab2/http.py index 00e547c..ec99cf4 100644 --- a/schemas/zgrab2/http.py +++ b/zgrab2_schemas/zgrab2/http.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 # lib/http/header.go: knownHeaders diff --git a/schemas/zgrab2/imap.py b/zgrab2_schemas/zgrab2/imap.py similarity index 94% rename from schemas/zgrab2/imap.py rename to zgrab2_schemas/zgrab2/imap.py index 9342f85..a1fb05e 100644 --- a/schemas/zgrab2/imap.py +++ b/zgrab2_schemas/zgrab2/imap.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 imap_scan_response = SubRecord({ diff --git a/schemas/zgrab2/modbus.py b/zgrab2_schemas/zgrab2/modbus.py similarity index 97% rename from schemas/zgrab2/modbus.py rename to zgrab2_schemas/zgrab2/modbus.py index 4716c90..eca30d7 100644 --- a/schemas/zgrab2/modbus.py +++ b/zgrab2_schemas/zgrab2/modbus.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 mei_object_names = [ diff --git a/schemas/zgrab2/mssql.py b/zgrab2_schemas/zgrab2/mssql.py similarity index 96% rename from schemas/zgrab2/mssql.py rename to zgrab2_schemas/zgrab2/mssql.py index 9111b0c..4a8208d 100644 --- a/schemas/zgrab2/mssql.py +++ b/zgrab2_schemas/zgrab2/mssql.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 ENCRYPT_MODES = [ diff --git a/schemas/zgrab2/mysql.py b/zgrab2_schemas/zgrab2/mysql.py similarity index 98% rename from schemas/zgrab2/mysql.py rename to zgrab2_schemas/zgrab2/mysql.py index e88e350..56006dd 100644 --- a/schemas/zgrab2/mysql.py +++ b/zgrab2_schemas/zgrab2/mysql.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 from zgrab2 import DebugOnly diff --git a/schemas/zgrab2/ntp.py b/zgrab2_schemas/zgrab2/ntp.py similarity index 97% rename from schemas/zgrab2/ntp.py rename to zgrab2_schemas/zgrab2/ntp.py index a438283..9fe9fd7 100644 --- a/schemas/zgrab2/ntp.py +++ b/zgrab2_schemas/zgrab2/ntp.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 ntp_short = SubRecord({ diff --git a/schemas/zgrab2/oracle.py b/zgrab2_schemas/zgrab2/oracle.py similarity index 99% rename from schemas/zgrab2/oracle.py rename to zgrab2_schemas/zgrab2/oracle.py index 07a7d78..d3b68f0 100644 --- a/schemas/zgrab2/oracle.py +++ b/zgrab2_schemas/zgrab2/oracle.py @@ -5,7 +5,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 FlagsSet = zgrab2.FlagsSet diff --git a/schemas/zgrab2/pop3.py b/zgrab2_schemas/zgrab2/pop3.py similarity index 95% rename from schemas/zgrab2/pop3.py rename to zgrab2_schemas/zgrab2/pop3.py index bacea1e..c54deae 100644 --- a/schemas/zgrab2/pop3.py +++ b/zgrab2_schemas/zgrab2/pop3.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 pop3_scan_response = SubRecord({ diff --git a/schemas/zgrab2/postgres.py b/zgrab2_schemas/zgrab2/postgres.py similarity index 98% rename from schemas/zgrab2/postgres.py rename to zgrab2_schemas/zgrab2/postgres.py index 233d1dd..52a60bb 100644 --- a/schemas/zgrab2/postgres.py +++ b/zgrab2_schemas/zgrab2/postgres.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 # modules/postgres/scanner.go - decodeError() (TODO: Currently an unconstrained diff --git a/schemas/zgrab2/redis.py b/zgrab2_schemas/zgrab2/redis.py similarity index 97% rename from schemas/zgrab2/redis.py rename to zgrab2_schemas/zgrab2/redis.py index 9aaedb7..b55398d 100644 --- a/schemas/zgrab2/redis.py +++ b/zgrab2_schemas/zgrab2/redis.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 redis_scan_response = SubRecord({ diff --git a/schemas/zgrab2/siemens.py b/zgrab2_schemas/zgrab2/siemens.py similarity index 95% rename from schemas/zgrab2/siemens.py rename to zgrab2_schemas/zgrab2/siemens.py index da504d5..53ec8c3 100644 --- a/schemas/zgrab2/siemens.py +++ b/zgrab2_schemas/zgrab2/siemens.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 siemens_scan_response = SubRecord({ diff --git a/schemas/zgrab2/smb.py b/zgrab2_schemas/zgrab2/smb.py similarity index 97% rename from schemas/zgrab2/smb.py rename to zgrab2_schemas/zgrab2/smb.py index 7638f97..119f9d3 100644 --- a/schemas/zgrab2/smb.py +++ b/zgrab2_schemas/zgrab2/smb.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 header_log = { diff --git a/schemas/zgrab2/smtp.py b/zgrab2_schemas/zgrab2/smtp.py similarity index 93% rename from schemas/zgrab2/smtp.py rename to zgrab2_schemas/zgrab2/smtp.py index 50589d2..b00f8cd 100644 --- a/schemas/zgrab2/smtp.py +++ b/zgrab2_schemas/zgrab2/smtp.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 smtp_scan_response = SubRecord({ diff --git a/schemas/zgrab2/ssh.py b/zgrab2_schemas/zgrab2/ssh.py similarity index 99% rename from schemas/zgrab2/ssh.py rename to zgrab2_schemas/zgrab2/ssh.py index 845ca18..d8ed427 100644 --- a/schemas/zgrab2/ssh.py +++ b/zgrab2_schemas/zgrab2/ssh.py @@ -5,7 +5,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 # NOTE: Despite the fact that we have e.g. "supportedHostKeyAlgos", diff --git a/schemas/zgrab2/telnet.py b/zgrab2_schemas/zgrab2/telnet.py similarity index 94% rename from schemas/zgrab2/telnet.py rename to zgrab2_schemas/zgrab2/telnet.py index e063bd7..c901f1e 100644 --- a/schemas/zgrab2/telnet.py +++ b/zgrab2_schemas/zgrab2/telnet.py @@ -4,7 +4,7 @@ from zschema.leaves import * from zschema.compounds import * import zschema.registry -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto import zgrab2 telnet_option = SubRecord({ diff --git a/schemas/zgrab2/testdata/ftp-authtls.json b/zgrab2_schemas/zgrab2/testdata/ftp-authtls.json similarity index 100% rename from schemas/zgrab2/testdata/ftp-authtls.json rename to zgrab2_schemas/zgrab2/testdata/ftp-authtls.json diff --git a/schemas/zgrab2/testdata/ftp-default.json b/zgrab2_schemas/zgrab2/testdata/ftp-default.json similarity index 100% rename from schemas/zgrab2/testdata/ftp-default.json rename to zgrab2_schemas/zgrab2/testdata/ftp-default.json diff --git a/schemas/zgrab2/testdata/http-http.json b/zgrab2_schemas/zgrab2/testdata/http-http.json similarity index 100% rename from schemas/zgrab2/testdata/http-http.json rename to zgrab2_schemas/zgrab2/testdata/http-http.json diff --git a/schemas/zgrab2/testdata/http-https.json b/zgrab2_schemas/zgrab2/testdata/http-https.json similarity index 100% rename from schemas/zgrab2/testdata/http-https.json rename to zgrab2_schemas/zgrab2/testdata/http-https.json diff --git a/schemas/zgrab2/testdata/mssql-2017-linux.json b/zgrab2_schemas/zgrab2/testdata/mssql-2017-linux.json similarity index 100% rename from schemas/zgrab2/testdata/mssql-2017-linux.json rename to zgrab2_schemas/zgrab2/testdata/mssql-2017-linux.json diff --git a/schemas/zgrab2/testdata/mysql-5.5.json b/zgrab2_schemas/zgrab2/testdata/mysql-5.5.json similarity index 100% rename from schemas/zgrab2/testdata/mysql-5.5.json rename to zgrab2_schemas/zgrab2/testdata/mysql-5.5.json diff --git a/schemas/zgrab2/testdata/mysql-5.6.json b/zgrab2_schemas/zgrab2/testdata/mysql-5.6.json similarity index 100% rename from schemas/zgrab2/testdata/mysql-5.6.json rename to zgrab2_schemas/zgrab2/testdata/mysql-5.6.json diff --git a/schemas/zgrab2/testdata/mysql-5.7.json b/zgrab2_schemas/zgrab2/testdata/mysql-5.7.json similarity index 100% rename from schemas/zgrab2/testdata/mysql-5.7.json rename to zgrab2_schemas/zgrab2/testdata/mysql-5.7.json diff --git a/schemas/zgrab2/testdata/mysql-8.0.json b/zgrab2_schemas/zgrab2/testdata/mysql-8.0.json similarity index 100% rename from schemas/zgrab2/testdata/mysql-8.0.json rename to zgrab2_schemas/zgrab2/testdata/mysql-8.0.json diff --git a/schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST.json b/zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST.json rename to zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST.json diff --git a/schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1.json b/zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1.json rename to zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1.json diff --git a/schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1_solo.json b/zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1_solo.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1_solo.json rename to zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_1_solo.json diff --git a/schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_solo.json b/zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_solo.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_solo.json rename to zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_REQ_MON_GETLIST_solo.json diff --git a/schemas/zgrab2/testdata/ntp-4.2.6_monlist.json b/zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_monlist.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-4.2.6_monlist.json rename to zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_monlist.json diff --git a/schemas/zgrab2/testdata/ntp-4.2.6_normal.json b/zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_normal.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-4.2.6_normal.json rename to zgrab2_schemas/zgrab2/testdata/ntp-4.2.6_normal.json diff --git a/schemas/zgrab2/testdata/ntp-openntp.json b/zgrab2_schemas/zgrab2/testdata/ntp-openntp.json similarity index 100% rename from schemas/zgrab2/testdata/ntp-openntp.json rename to zgrab2_schemas/zgrab2/testdata/ntp-openntp.json diff --git a/schemas/zgrab2/testdata/pop3-banner.json b/zgrab2_schemas/zgrab2/testdata/pop3-banner.json similarity index 100% rename from schemas/zgrab2/testdata/pop3-banner.json rename to zgrab2_schemas/zgrab2/testdata/pop3-banner.json diff --git a/schemas/zgrab2/testdata/pop3-banner.quit.json b/zgrab2_schemas/zgrab2/testdata/pop3-banner.quit.json similarity index 100% rename from schemas/zgrab2/testdata/pop3-banner.quit.json rename to zgrab2_schemas/zgrab2/testdata/pop3-banner.quit.json diff --git a/schemas/zgrab2/testdata/pop3-help.banner.quit.json b/zgrab2_schemas/zgrab2/testdata/pop3-help.banner.quit.json similarity index 100% rename from schemas/zgrab2/testdata/pop3-help.banner.quit.json rename to zgrab2_schemas/zgrab2/testdata/pop3-help.banner.quit.json diff --git a/schemas/zgrab2/testdata/pop3-noop.help.banner.quit.json b/zgrab2_schemas/zgrab2/testdata/pop3-noop.help.banner.quit.json similarity index 100% rename from schemas/zgrab2/testdata/pop3-noop.help.banner.quit.json rename to zgrab2_schemas/zgrab2/testdata/pop3-noop.help.banner.quit.json diff --git a/schemas/zgrab2/testdata/postgres-10.1-nossl.json b/zgrab2_schemas/zgrab2/testdata/postgres-10.1-nossl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-10.1-nossl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-10.1-nossl.json diff --git a/schemas/zgrab2/testdata/postgres-10.1-ssl.json b/zgrab2_schemas/zgrab2/testdata/postgres-10.1-ssl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-10.1-ssl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-10.1-ssl.json diff --git a/schemas/zgrab2/testdata/postgres-9.3-nossl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.3-nossl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.3-nossl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.3-nossl.json diff --git a/schemas/zgrab2/testdata/postgres-9.3-ssl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.3-ssl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.3-ssl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.3-ssl.json diff --git a/schemas/zgrab2/testdata/postgres-9.4-nossl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.4-nossl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.4-nossl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.4-nossl.json diff --git a/schemas/zgrab2/testdata/postgres-9.4-ssl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.4-ssl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.4-ssl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.4-ssl.json diff --git a/schemas/zgrab2/testdata/postgres-9.5-nossl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.5-nossl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.5-nossl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.5-nossl.json diff --git a/schemas/zgrab2/testdata/postgres-9.5-ssl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.5-ssl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.5-ssl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.5-ssl.json diff --git a/schemas/zgrab2/testdata/postgres-9.6-nossl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.6-nossl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.6-nossl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.6-nossl.json diff --git a/schemas/zgrab2/testdata/postgres-9.6-ssl.json b/zgrab2_schemas/zgrab2/testdata/postgres-9.6-ssl.json similarity index 100% rename from schemas/zgrab2/testdata/postgres-9.6-ssl.json rename to zgrab2_schemas/zgrab2/testdata/postgres-9.6-ssl.json diff --git a/schemas/zgrab2/testdata/redis-default-inline.json b/zgrab2_schemas/zgrab2/testdata/redis-default-inline.json similarity index 100% rename from schemas/zgrab2/testdata/redis-default-inline.json rename to zgrab2_schemas/zgrab2/testdata/redis-default-inline.json diff --git a/schemas/zgrab2/testdata/redis-default-normal.json b/zgrab2_schemas/zgrab2/testdata/redis-default-normal.json similarity index 100% rename from schemas/zgrab2/testdata/redis-default-normal.json rename to zgrab2_schemas/zgrab2/testdata/redis-default-normal.json diff --git a/schemas/zgrab2/testdata/redis-password-inline.json b/zgrab2_schemas/zgrab2/testdata/redis-password-inline.json similarity index 100% rename from schemas/zgrab2/testdata/redis-password-inline.json rename to zgrab2_schemas/zgrab2/testdata/redis-password-inline.json diff --git a/schemas/zgrab2/testdata/redis-password-normal.json b/zgrab2_schemas/zgrab2/testdata/redis-password-normal.json similarity index 100% rename from schemas/zgrab2/testdata/redis-password-normal.json rename to zgrab2_schemas/zgrab2/testdata/redis-password-normal.json diff --git a/schemas/zgrab2/testdata/redis-renamed-inline.json b/zgrab2_schemas/zgrab2/testdata/redis-renamed-inline.json similarity index 100% rename from schemas/zgrab2/testdata/redis-renamed-inline.json rename to zgrab2_schemas/zgrab2/testdata/redis-renamed-inline.json diff --git a/schemas/zgrab2/testdata/redis-renamed-normal.json b/zgrab2_schemas/zgrab2/testdata/redis-renamed-normal.json similarity index 100% rename from schemas/zgrab2/testdata/redis-renamed-normal.json rename to zgrab2_schemas/zgrab2/testdata/redis-renamed-normal.json diff --git a/schemas/zgrab2/testdata/smtp-00.json b/zgrab2_schemas/zgrab2/testdata/smtp-00.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-00.json rename to zgrab2_schemas/zgrab2/testdata/smtp-00.json diff --git a/schemas/zgrab2/testdata/smtp-ehlo.03.json b/zgrab2_schemas/zgrab2/testdata/smtp-ehlo.03.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-ehlo.03.json rename to zgrab2_schemas/zgrab2/testdata/smtp-ehlo.03.json diff --git a/schemas/zgrab2/testdata/smtp-ehlo.04.json b/zgrab2_schemas/zgrab2/testdata/smtp-ehlo.04.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-ehlo.04.json rename to zgrab2_schemas/zgrab2/testdata/smtp-ehlo.04.json diff --git a/schemas/zgrab2/testdata/smtp-ehlo.quit.05.json b/zgrab2_schemas/zgrab2/testdata/smtp-ehlo.quit.05.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-ehlo.quit.05.json rename to zgrab2_schemas/zgrab2/testdata/smtp-ehlo.quit.05.json diff --git a/schemas/zgrab2/testdata/smtp-helo.01.json b/zgrab2_schemas/zgrab2/testdata/smtp-helo.01.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-helo.01.json rename to zgrab2_schemas/zgrab2/testdata/smtp-helo.01.json diff --git a/schemas/zgrab2/testdata/smtp-helo.02.json b/zgrab2_schemas/zgrab2/testdata/smtp-helo.02.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-helo.02.json rename to zgrab2_schemas/zgrab2/testdata/smtp-helo.02.json diff --git a/schemas/zgrab2/testdata/smtp-help.quit.06.json b/zgrab2_schemas/zgrab2/testdata/smtp-help.quit.06.json similarity index 100% rename from schemas/zgrab2/testdata/smtp-help.quit.06.json rename to zgrab2_schemas/zgrab2/testdata/smtp-help.quit.06.json diff --git a/schemas/zgrab2/testdata/ssh-ssh.json b/zgrab2_schemas/zgrab2/testdata/ssh-ssh.json similarity index 100% rename from schemas/zgrab2/testdata/ssh-ssh.json rename to zgrab2_schemas/zgrab2/testdata/ssh-ssh.json diff --git a/schemas/zgrab2/testdata/telnet-telnet.json b/zgrab2_schemas/zgrab2/testdata/telnet-telnet.json similarity index 100% rename from schemas/zgrab2/testdata/telnet-telnet.json rename to zgrab2_schemas/zgrab2/testdata/telnet-telnet.json diff --git a/schemas/zgrab2/tests.py b/zgrab2_schemas/zgrab2/tests.py similarity index 100% rename from schemas/zgrab2/tests.py rename to zgrab2_schemas/zgrab2/tests.py diff --git a/schemas/zgrab2/zgrab2.py b/zgrab2_schemas/zgrab2/zgrab2.py similarity index 98% rename from schemas/zgrab2/zgrab2.py rename to zgrab2_schemas/zgrab2/zgrab2.py index 16bc9d0..bbde2b2 100644 --- a/schemas/zgrab2/zgrab2.py +++ b/zgrab2_schemas/zgrab2/zgrab2.py @@ -5,7 +5,7 @@ from collections import defaultdict # Base / shared schema types for zgrab2 -import schemas.zcrypto +import zcrypto_schemas.zcrypto as zcrypto # Map of protocol-name -> protocl-schema. This is wrapped in a SubRecord # Protocols are responsible for calling register_scan_response_type(protocol_name, schema).