Skip to content

Commit a487517

Browse files
Don Johnsoncoolaj86
authored andcommitted
feat: add feroxbuster (forced browsing security tool)
1 parent bf5482c commit a487517

File tree

4 files changed

+174
-0
lines changed

4 files changed

+174
-0
lines changed

feroxbuster/README.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
---
2+
title: feroxbuster
3+
homepage: https://github.com/epi052/feroxbuster
4+
tagline: |
5+
feroxbuster: A tool designed to perform Forced Browsing.
6+
---
7+
8+
To update or switch versions, run `webi feroxbuster@stable` (or `@v2`, `@beta`,
9+
etc).
10+
11+
### Files
12+
13+
These are the files / directories that are created and/or modified with this
14+
install:
15+
16+
```text
17+
~/.config/feroxbuster/ferox-config.toml
18+
~/.local/bin/feroxbuster
19+
```
20+
21+
## Cheat Sheet
22+
23+
> `feroxbuster` is a tool designed for Forced Browsing. Forced browsing is an
24+
> attack where the aim is to enumerate and access resources that are not
25+
> referenced by the web application but are still accessible by an attacker.
26+
27+
To run feroxbuster:
28+
29+
```sh
30+
feroxbuster -u [target]
31+
```
32+
33+
### Include Headers
34+
35+
To run feroxbuster with custom headers:
36+
37+
```sh
38+
feroxbuster -u [target] -H Accept:application/json "Authorization: Bearer {token}"
39+
```
40+
41+
### Proxy Traffic Through Burp
42+
43+
To proxy traffic through Burp:
44+
45+
```sh
46+
feroxbuster -u [target] --insecure --proxy http://127.0.0.1:8080
47+
```

feroxbuster/install.ps1

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
#!/usr/bin/env pwsh
2+
3+
##################
4+
# Install feroxbuster #
5+
##################
6+
7+
# Every package should define these variables
8+
$pkg_cmd_name = "feroxbuster"
9+
10+
$pkg_dst_cmd = "$Env:USERPROFILE\.local\bin\feroxbuster.exe"
11+
$pkg_dst = "$pkg_dst_cmd"
12+
13+
$pkg_src_cmd = "$Env:USERPROFILE\.local\opt\feroxbuster-v$Env:WEBI_VERSION\bin\feroxbuster.exe"
14+
$pkg_src_bin = "$Env:USERPROFILE\.local\opt\feroxbuster-v$Env:WEBI_VERSION\bin"
15+
$pkg_src_dir = "$Env:USERPROFILE\.local\opt\feroxbuster-v$Env:WEBI_VERSION"
16+
$pkg_src = "$pkg_src_cmd"
17+
18+
New-Item "$Env:USERPROFILE\Downloads\webi" -ItemType Directory -Force | out-null
19+
$pkg_download = "$Env:USERPROFILE\Downloads\webi\$Env:WEBI_PKG_FILE"
20+
21+
# Fetch archive
22+
IF (!(Test-Path -Path "$Env:USERPROFILE\Downloads\webi\$Env:WEBI_PKG_FILE"))
23+
{
24+
echo "Downloading feroxbuster from $Env:WEBI_PKG_URL to $pkg_download"
25+
& curl.exe -A "$Env:WEBI_UA" -fsSL "$Env:WEBI_PKG_URL" -o "$pkg_download.part"
26+
& move "$pkg_download.part" "$pkg_download"
27+
}
28+
29+
IF (!(Test-Path -Path "$pkg_src_cmd"))
30+
{
31+
echo "Installing feroxbuster"
32+
33+
# TODO: create package-specific temp directory
34+
# Enter tmp
35+
pushd .local\tmp
36+
37+
# Remove any leftover tmp cruft
38+
Remove-Item -Path ".\feroxbuster-v*" -Recurse -ErrorAction Ignore
39+
Remove-Item -Path ".\feroxbuster.exe" -Recurse -ErrorAction Ignore
40+
41+
# NOTE: DELETE THIS COMMENT IF NOT USED
42+
# Move single binary into root of temporary folder
43+
#& move "$pkg_download" "feroxbuster.exe"
44+
45+
# Unpack archive file into this temporary directory
46+
# Windows BSD-tar handles zip. Imagine that.
47+
echo "Unpacking $pkg_download"
48+
& tar xf "$pkg_download"
49+
50+
# Settle unpacked archive into place
51+
echo "Install Location: $pkg_src_cmd"
52+
New-Item "$pkg_src_bin" -ItemType Directory -Force | out-null
53+
Move-Item -Path ".\feroxbuster-*\feroxbuster.exe" -Destination "$pkg_src_bin"
54+
55+
# Exit tmp
56+
popd
57+
}
58+
59+
echo "Copying into '$pkg_dst_cmd' from '$pkg_src_cmd'"
60+
Remove-Item -Path "$pkg_dst_cmd" -Recurse -ErrorAction Ignore | out-null
61+
Copy-Item -Path "$pkg_src" -Destination "$pkg_dst" -Recurse

feroxbuster/install.sh

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
#!/bin/sh
2+
3+
# shellcheck disable=SC2034
4+
# "'pkg_cmd_name' appears unused. Verify it or export it."
5+
6+
__init_feroxbuster() {
7+
set -e
8+
set -u
9+
10+
##################
11+
# Install feroxbuster #
12+
##################
13+
14+
# Every package should define these 6 variables
15+
pkg_cmd_name="feroxbuster"
16+
17+
pkg_dst_cmd="$HOME/.local/bin/feroxbuster"
18+
pkg_dst="$pkg_dst_cmd"
19+
20+
pkg_src_cmd="$HOME/.local/opt/feroxbuster-v$WEBI_VERSION/bin/feroxbuster"
21+
pkg_src_dir="$HOME/.local/opt/feroxbuster-v$WEBI_VERSION"
22+
pkg_src="$pkg_src_cmd"
23+
24+
# pkg_install must be defined by every package
25+
pkg_install() {
26+
# ~/.local/opt/feroxbuster-v0.99.9/bin
27+
mkdir -p "$(dirname "${pkg_src_cmd}")"
28+
29+
# mv ./feroxbuster-*/feroxbuster ~/.local/opt/feroxbuster-v0.99.9/bin/feroxbuster
30+
mv ./feroxbuster "${pkg_src_cmd}"
31+
}
32+
33+
# pkg_get_current_version is recommended, but not required
34+
pkg_get_current_version() {
35+
# 'feroxbuster --version' has output in this format:
36+
# feroxbuster 0.99.9 (rev abcdef0123)
37+
# This trims it down to just the version number:
38+
# 0.99.9
39+
feroxbuster --version 2> /dev/null |
40+
head -n 1 |
41+
cut -d ' ' -f 2
42+
}
43+
44+
}
45+
46+
__init_feroxbuster

feroxbuster/releases.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
'use strict';
2+
3+
var github = require('../_common/github.js');
4+
var owner = 'epi052';
5+
var repo = 'feroxbuster';
6+
7+
module.exports = function (request) {
8+
return github(request, owner, repo).then(function (all) {
9+
return all;
10+
});
11+
};
12+
13+
if (module === require.main) {
14+
module.exports(require('@root/request')).then(function (all) {
15+
all = require('../_webi/normalize.js')(all);
16+
// just select the first 5 for demonstration
17+
all.releases = all.releases.slice(0, 5);
18+
console.info(JSON.stringify(all, null, 2));
19+
});
20+
}

0 commit comments

Comments
 (0)