如何使用Bypass-Url-Parser实现URL绕过并访问40X受保护页面

news2024/9/30 17:33:48

关于Bypass-Url-Parser

Bypass-Url-Parser是一款功能强大的URL绕过工具,该工具可以使用多种方法实现URL绕过并访问目标站点的40X受保护页面。

工具下载

由于该工具基于Python 3 开发,因此我们首先需要在本地设备上安装并配置好Python 3环境。接下来,使用下列命令将该项目源码克隆至本地:

git clone https://github.com/laluka/bypass-url-parser.git

Linux配置

# Deps

sudo apt install -y bat curl virtualenv python3

# Tool

virtualenv -p python3 .py3

source .py3/bin/activate

pip install -r requirements.txt

./bypass_url_parser.py -u http://thinkloveshare.com/juicy_403_endpoint/

Docker配置

docker build -t thelaluka/bypass-url-parser:latest .

docker run --rm -it --net=host -v "$PWD:/host" thelaluka/bypass-url-parser:latest -u http://127.0.0.1:8000/dummy

docker run --rm -it --net=host -v "$PWD:/host" thelaluka/bypass-url-parser:latest -u /host/urls.lst

# TODO later, tag & push releases to dockerhub :)

# -t thelaluka/bypass-url-parser:0.2.0

# docker push thelaluka/bypass-url-parser:latest

工具使用

Bypass Url Parser, made with love by @TheLaluka

A tool that tests MANY url bypasses to reach a 40X protected page.

 

Usage:

    ./bypass_url_parser.py -u <URL> [-m <mode>] [-o <outdir>] [-S <level>] [(-H <header>)...] [-r <num>]

                           [-s <ip>] [--spoofip-replace] [-p <port>] [--spoofport-replace] [--dump-payloads]

                           [-t <threads>] [-T <timeout>] [-x <proxy_url>] [-v | -d | -dd]

 

Program options:

    -H, --header <header>     设置要使用的Header,格式为"Cookie: can_i_haz=fire"

    -m, --mode <mode>      设置绕过模式[默认: all]

    -o, --outdir <outdir>       结果的输出目录

    -x, --proxy <proxy_url>    设置代理,格式为http://proxy_ip:port.

    -S, --save-level <level>    存储结果等级,从0(禁用)到3(完整)[默认: 1]

    -s, --spoofip <ip>         注入到ip-specific头中的IP地址

    -p, --spoofport <port>     注入到port-specific头中的端口号

    -r, --retry <num>          失败后的重试次数 [默认: 3]

    -t, --threads <threads>     设置扫描并行线程[默认: 1]

    -T, --timeout <timeout>    Request times out after N seconds [默认: 5]

    -u, --url <URL>           待绕过的目标URL

 

General options:

    -h, --help                显示工具帮助信息

    -v, --verbose             Verbose模式输出

    -d, --debug              显示调试信息

    -dd, --debug             开启二级调试模式,显示所有的类输出

    -V, --version             显示工具版本信息

 

Misc options:

    --spoofip-replace         在'http_headers_ip'绕过模式下禁用显示内部IP列表

    --spoofport-replace       在'http_headers_port'模式下禁用显示内部端口列表    

--dump-payloads         打印该工具生成的所有Payload

 

样例:

    ./bypass_url_parser.py -u "http://127.0.0.1/juicy_403_endpoint/" -s 8.8.8.8 -d

    ./bypass_url_parser.py -u /path/urls -t 30 -T 5 -H "Cookie: me_iz=admin" -H "User-agent: test"

期望的输出结果

./bypass_url_parser.py -u http://127.0.0.1:8000/foo/bar

2022-08-09 14:52:40 lalu-perso bup[361559] WARNING Trying to bypass 'http://127.0.0.1:8000/foo/bar' url (1625 payloads)...

2022-08-09 14:52:40 lalu-perso bup[361559] INFO Doing: 50 / 1625

[...]

2022-08-09 14:52:54 lalu-perso bup[361559] INFO Doing: 1600 / 1625

2022-08-09 14:52:54 lalu-perso bup[361559] INFO Retry (1/3) the '16' failed curl commands with 10 threads and 10s timeout

2022-08-09 14:52:54 lalu-perso bup[361559] INFO Retry (2/3) the '16' failed curl commands with 5 threads and 20s timeout

2022-08-09 14:52:54 lalu-perso bup[361559] INFO Retry (3/3) the '16' failed curl commands with 1 threads and 30s timeout

2022-08-09 14:52:55 lalu-perso bup[361559] INFO

[#####] [bypass_method] [payload] => [status_code] [content_type] [content_length] [lines_count] [word_counts] [title] [server] [redirect_url]

[GROUP (1587)] [original_request] [http://127.0.0.1:8000/foo/bar] => [404] [text/html] [469] [14] [95] [Error response] [SimpleHTTP/0.6 Python/3.8.10] []

[GROUP (10)] [http_methods] [-X CONNECT http://127.0.0.1:8000/foo/bar] => [501] [text/html] [500] [14] [96] [Error response] [SimpleHTTP/0.6 Python/3.8.10] []

[SINGLE] [mid_paths] [http://127.0.0.1:8000/???foo/bar] => [200] [text/html] [913] [26] [27] [Directory listing for /???foo/bar] [SimpleHTTP/0.6 Python/3.8.10] []

[SINGLE] [mid_paths] [http://127.0.0.1:8000//???foo/bar] => [301] [] [] [0] [0] [] [SimpleHTTP/0.6 Python/3.8.10] [/???foo/bar]

[SINGLE] [mid_paths] [http://127.0.0.1:8000/??foo/bar] => [200] [text/html] [911] [26] [27] [Directory listing for /??foo/bar] [SimpleHTTP/0.6 Python/3.8.10] []

[SINGLE] [mid_paths] [http://127.0.0.1:8000//??foo/bar] => [301] [] [] [0] [0] [] [SimpleHTTP/0.6 Python/3.8.10] [/??foo/bar]

[SINGLE] [mid_paths] [http://127.0.0.1:8000/?foo/bar] => [200] [text/html] [909] [26] [27] [Directory listing for /?foo/bar] [SimpleHTTP/0.6 Python/3.8.10] []

[SINGLE] [mid_paths] [http://127.0.0.1:8000//?foo/bar] => [301] [] [] [0] [0] [] [SimpleHTTP/0.6 Python/3.8.10] [/?foo/bar]

[SINGLE] [mid_paths] [http://127.0.0.1:8000///?anythingfoo/bar] => [200] [text/html] [929] [26] [27] [Directory listing for ///?anythingfoo/bar] [SimpleHTTP/0.6 Python/3.8.10] []

[SINGLE] [mid_paths] [http://127.0.0.1:8000?anythingfoo/bar] => [200] [text/html] [931] [26] [27] [Directory listing for ?anythingfoo/bar] [SimpleHTTP/0.6 Python/3.8.10] []

[GROUP (2)] [mid_paths] [http://127.0.0.1:8000/#?foo/bar] => [200] [text/html] [893] [26] [27] [Directory listing for /] [SimpleHTTP/0.6 Python/3.8.10] []

[GROUP (2)] [mid_paths] [http://127.0.0.1:8000//#?foo/bar] => [301] [] [] [0] [0] [] [SimpleHTTP/0.6 Python/3.8.10] [/]

工具使用样例

参数解析

Bypass-Url-Parser支持以多种方式定义某些参数:

./bypass_url_parser.py -u http://thinkloveshare.com/test

./bypass_url_parser.py -u /path/urls

cat /path/urls | ./bypass_url_parser.py -u -

echo 'http://thinkloveshare.com/test' | ./bypass_url_parser.py -u -

绕过模式

当前版本的Bypass-Url-Parser支持下列绕过模式:

all, mid_paths, end_paths, case_substitution, char_encode, http_methods, http_versions, http_headers_scheme, http_headers_ip, http_headers_port

Spoofip / Spoofport

./bypass_url_parser.py -u /path/urls -s /path/custom_ip --spoofip-replace

./bypass_url_parser.py -u /path/urls -p "3000, 9443, 10443"

结果保存

默认配置下,如果目标为单个URL,工具会将运行结果存储到/tmp/tmpXXX-bypass-url-parser/triaged-
bypass.log日志文件中。使用样例如下:

./bypass_url_parser.py -S 0

./bypass_url_parser.py -o /tmp/bypass-res

./bypass_url_parser.py -o /tmp/bypass-res2 -S 2 -u http://thinkloveshare.com/juicy_403_endpoint/

tree /tmp/bypass-res2/

├── bypass-14193b8d2e14ec60d52405f46c5d35f3.html

├── bypass-782550777a661b7bef046b5d899b403a.html

├── bypass-e06268bcef8506053feed2646af4e773.html

├── bypass-ebdf6466c5ef82ab08a7b97324662bf0.html

└── triaged-bypass.log

 

0 directories, 5 files

非回归测试和代码清理

# Code Cleanup

isort --py 37 *.py

autopep8 -a --max-line-length 120 -i *.py

# Ensure no regression is pushed

./bypass_url_parser.py -S 0 -v -u http://127.0.0.1:8000/foo/bar --dump-payloads > "tests-history/bup-payloads-$(date +'%Y-%m-%d').lst"

# Compare /tmp/bup-payloads-YYYY-MM-DD.lst and the latest tests-history/bup-payloads-YYYY-MM-DD.lst

git diff --no-index tests-history/bup-payloads-[OLD].lst tests-history/bup-payloads-[NEW].lst

# TODO create ls/sort/diff bash command for maintainers

git commit -m "My cool feature or bugfix"

git tag -a vX.Y.Z "$COMMIT_HASH" -m "New release: vX.Y.Z"

git push --tags

# If X or Y is bumped, create new release on github

项目地址

Bypass-Url-Parser :【[ GitHub传送门](https://github.com/laluka/bypass-url-
parser)】

git tag -a vX.Y.Z "$COMMIT_HASH" -m "New release: vX.Y.Z"

git push --tags

# If X or Y is bumped, create new release on github

网络安全工程师企业级学习路线

这时候你当然需要一份系统性的学习路线

如图片过大被平台压缩导致看不清的话,可以在文末下载(无偿的),大家也可以一起学习交流一下。

一些我收集的网络安全自学入门书籍

一些我白嫖到的不错的视频教程:

上述资料【扫下方二维码】就可以领取了,无偿分享

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/380920.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

PLC实验—西门子S7 1200读取超声波传感器数据

PLC实验—西门子S7 1200读取超声波传感器数据 US-016超声波测距模块 实验箱上是US-016超声波测距模块&#xff0c;其有关信息可以看实验室的博客 US-016超声波测距模块 1号Pin&#xff1a;接VCC电源&#xff08;直流5V&#xff09; 2号Pin&#xff1a;量程设置引脚&#xff…

GWT安装过程

1:安装前准备 &#xff08;可以问我要&#xff09; appengine-java-sdk-1.9.8 com.google.gdt.eclipse.suite.4.3.update.site_3.8.0 gwt-2.5.1 eclipse-jee-kepler-SR2-win32-x86_64.zip 2&#xff1a;安装环境上 打开eclipse Help –Install New Software… 选择Add –…

如何使用工时表管理项目和非项目的资源?

对新机会做出反应的能力是企业竞争优势的关键。项目不断涌现&#xff0c;企业需要了解具体的可用性以及是否有资源来接受新事物。更进一步来说&#xff0c;企业需要知道员工将时间花在哪里。 使用 8Manage工时表解决方案&#xff0c;你将始终拥有做出正确业务决策所需的全面知…

vue源码分析-响应式系统工作原理

上一章&#xff0c;我们讲到了Vue初始化做的一些操作&#xff0c;那么我们这一章来讲一个Vue核心概念响应式系统。 我们先来看一下官方对深入响应式系统的解释: 当你把一个普通的 JavaScript 对象传给 Vue 实例的 data 选项&#xff0c;Vue 将遍历此对象所有的属性。 并使用 O…

LeetCode:构造最大二叉树;使用中序和后序数组构造二叉树;使用前序和中序数组遍历二叉树。

构造二叉树最好都是使用前序遍历&#xff1b;中左右的顺序。 654. 最大二叉树 中等 636 给定一个不重复的整数数组 nums 。 最大二叉树 可以用下面的算法从 nums 递归地构建: 创建一个根节点&#xff0c;其值为 nums 中的最大值。递归地在最大值 左边 的 子数组前缀上 构建…

人力资源管理系统

技术&#xff1a;Java、JSP等摘要&#xff1a;在当今的信息化社会&#xff0c;为了更有效率地工作&#xff0c;人们充分利用现在的电子信息技术&#xff0c;在办公室架设起办公服务平台&#xff0c;将人力资源相关信息统一起来管理&#xff0c;帮助管理者有效组织降低成本和加速…

【Linux】gcc/g++/gdb的使用

&#x1f525;&#x1f525; 欢迎来到小林的博客&#xff01;&#xff01;       &#x1f6f0;️博客主页&#xff1a;✈️小林爱敲代码       &#x1f6f0;️社区 : 进步学堂       &#x1f6f0;️欢迎关注&#xff1a;&#x1f44d;点赞&#x1f64c;收…

Mask R-CNN 算法学习总结

Mask R-CNN 相关知识点整体框架1.Resnet 深度残差学习1.1 目的1.2 深度学习深度增加带来的问题1.3 Resnet实现思想【添加恒等映射】2.线性插值2.1 目的2.2 线性插值原理2.3 为什么使用线性插值?3.FPN 特征金字塔3.1 FPN介绍3.2 为什么使用FPN?3.3 自下而上层【提取特征】3.4 …

反激与正激的区别

之前学习了正激开关电源&#xff0c;但是对于正激和反激一直不是很清楚&#xff0c;网上找了一篇&#xff0c;觉得感觉该可以&#xff0c;以此记录。正激和反激是两种不同的开关电源技术一、正激&#xff08;1&#xff09;概述正激式开关电源是指使用正激高频变压器隔离耦合能量…

深度学习笔记:神经网络权重确定初始值方法

神经网络权重不可为相同的值&#xff0c;比如都为0&#xff0c;因为如果这样网络正向传播输出和反向传播结果对于各权重都完全一样&#xff0c;导致设置多个权重和设一个权重毫无区别。我们需要使用随机数作为网络权重 实验程序 在以下实验中&#xff0c;我们使用5层神经网络…

设计模式-服务定位器模式

设计模式-服务定位器模式一、背景1.1 服务定位模式1.2 策略模式二、代码实战2.1 服务定位器2.2 配置ServiceLocatorFactoryBean2.3 定义一个支付的接口2.4 根据不同类型处理Bean2.5 controller层三、项目结构及测试结果3.1 测试结果3.2 项目结构及源码(欢迎star)四、参考资料一…

进程管理(进程概念、查看进程、关闭进程)

1.进程 程序运行在操作系统中&#xff0c;是被操作系统所管理的。 为管理运行的程序&#xff0c;每一个程序运行的时候&#xff0c;便被操作系统注册为系统中的一个&#xff1a;进程 并会为每一个进程都分配一个独有的&#xff1a;进程ID&#xff08;进程号&#xff09; 2. 查…

Paddle OCR Win 11下的安装和简单使用教程

Paddle OCR Win 11下的安装和简单使用教程 对于中文的识别&#xff0c;可以考虑直接使用Paddle OCR&#xff0c;识别准确率和部署都相对比较方便。 环境搭建 目前PaddlePaddle 发布到v2.4&#xff0c;先下载paddlepaddle&#xff0c;再下载paddleocr。根据自己设备操作系统进…

代码随想录算法训练营第四十天 | 343. 整数拆分,96.不同的二叉搜索树

一、参考资料整数拆分https://programmercarl.com/0343.%E6%95%B4%E6%95%B0%E6%8B%86%E5%88%86.html 视频讲解&#xff1a;https://www.bilibili.com/video/BV1Mg411q7YJ不同的二叉搜索树https://programmercarl.com/0096.%E4%B8%8D%E5%90%8C%E7%9A%84%E4%BA%8C%E5%8F%89%E6%90…

Win10任务栏卡死的几个处理方法 附小工具

问题&#xff1a;Win10任务栏卡死 最近经常碰到用户系统任务栏卡死的现象&#xff0c;桌面上的图标可以正常打开&#xff0c;点击任务栏就疯狂的转圈&#xff0c;感觉像死机状态&#xff0c;等半天都没啥用&#xff0c;一般只能强制关机重启&#xff0c;我不建议这样操作&…

机器学习算法原理——感知机

感知机 输入空间&#xff1a;X⊆Rn\mathcal X\subseteq{\bf R^n}X⊆Rn &#xff1b;输入&#xff1a;x(x(1),x(2),⋅⋅⋅,x(n))T∈Xx\left(x^{(1)},x^{(2)},\cdot\cdot\cdot,x^{(n)}\right)^{T}\in{\mathcal{X}}x(x(1),x(2),⋅⋅⋅,x(n))T∈X 输出空间&#xff1a;Y{1,−1}{\…

杂谈:created中两次数据修改,会触发几次页面更新?

面试题&#xff1a;created生命周期中两次修改数据&#xff0c;会触发几次页面更新&#xff1f; 一、同步的 先举个简单的同步的例子&#xff1a; new Vue({el: "#app",template: <div><div>{{count}}</div></div>,data() {return {count…

[架构之路-124]-《软考-系统架构设计师》-操作系统-3-操作系统原理 - IO设备、微内核、嵌入式系统

第11章 操作系统第5节 设备管理/文件管理&#xff1a;IO5.1 文件管理5.2 IO设备管理&#xff08;内存与IO设备之间&#xff09;数据传输控制是指如何在内存和IO硬件设备之间传输数据&#xff0c;即&#xff1a;设备何时空闲&#xff1f;设备何时完成数据的传输&#xff1f;SPOO…

vue实战-深入响应式数据原理

本文将带大家快速过一遍Vue数据响应式原理&#xff0c;解析源码&#xff0c;学习设计思路&#xff0c;循序渐进。 数据初始化 _init 在我们执行new Vue创建实例时&#xff0c;会调用如下构造函数&#xff0c;在该函数内部调用this._init(options)。 import { initMixin } f…

代码随想录算法训练营第一天| 704. 二分查找、27. 移除元素

Leetcode 704 二分查找题目链接&#xff1a;704二分查找介绍给定一个 n 个元素有序的&#xff08;升序&#xff09;整型数组 nums 和一个目标值 target &#xff0c;写一个函数搜索 nums 中的 target&#xff0c;如果目标值存在返回下标&#xff0c;否则返回 -1。思路先看看一个…