• Stars
    star
    513
  • Rank 86,178 (Top 2 %)
  • Language
    Python
  • License
    GNU General Publi...
  • Created over 8 years ago
  • Updated about 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

BFAC (Backup File Artifacts Checker): An automated tool that checks for backup artifacts that may disclose the web-application's source code.

BFAC

Advanced Backup-File Artifacts Testing for Web-Applications

BFAC

BFAC (Backup File Artifacts Checker) is an automated tool that checks for backup artifacts that may disclose the web-application's source code. The artifacts can also lead to leakage of sensitive information, such as passwords, directory structure, etc.

The goal of BFAC is to be an all-in-one tool for backup-file artifacts black-box testing.

Features

  • Multithreaded scanning.
  • Includes request rate throttling.
  • HTTP proxy support.
  • Uses multiple algorithms for automatically detecting valid and invalid pages.
  • HTTP proxy support
  • User agent randomization.
  • Batch processing.
  • Works both as a command-line tool and Python module.
  • Support for Windows, MacOS, and Linux operating systems.
  • Reporting: simple, verbose, CSV, JSON.

Usage

Description Command
Help bfac --help
Check a single URL. bfac --url http://example.com/test.php
Check a list of URLs. bfac --list testing_list.txt
Single URL with a different level (level 2 for example). bfac --url http://example.com/test.php --level 2
Single URL and show the results only. bfac --no-text --url http://example.com/test.php
Limit the test to exposed DVCS tests. bfac --dvcs-test --url http://example.com/
Verify existence of files using Content-Length checks only. bfac --detection-technique content_length http://example.com/test.php
Verify existence of files using Status-Code checks only. bfac --detection-technique status_code http://example.com/test.php
Exclude results with specific status-codes. bfac --exclude-status-codes 301,999 http://example.com/test.php

Using BFAC as a module

import bfac


testing_level = 5

# Returns a list of BFA patterns for http://example.com/test.php
bfa_urls = bfac.generate_bfa_urls(
    'http://example.com/test.php', testing_level=testing_level)

# Performs BFA testing using BFAC, and returns a list of findings, if any.
# If nothing is identified, it returns an empty list.
bfa_testing_result = bfac.test_url(
    'http://example.com/test.php', testing_level=testing_level)

Requirements

  • Python2 or Python3
  • requests
  • colorama

Installation [Optional]

sudo python setup.py install

Compatibility

The project currently supports all platforms that run Python. The project is compatible with both Python 2 and Python 3.

Frequently Asked Questions

Q: How to use BFAC with all levels?

A: BFAC runs with all levels by default. if you would like to decrease the used testing level, you can do it by setting the --level flag to a lower value.

Q: How do BFAC determines if the file actually exists on the web-server or not?

A: BFAC approach regarding detection differs from regular security tools.

Regular security tools determinate if a file exists on a server by checking the HTTP status code. Since there are system administrators that might spoof HTTP status codes for HTTP requests to fool security tools and bots, BFAC implemented an additional method.

It checks for the general response of an invalid or non-available web resource. Then, it sends requests and compare the response size of the request with the initial base.

  • --detection-technique all uses both methods for HTTP Status Code checks, and the HTTP Content-Length.
  • --detection-technique status_code: uses HTTP status code checks only.
  • --detection-technique content_length: uses HTTP Content-Length checks only.

Community Contribution

Contribution from the community to the BFAC project is very welcome. If you find a bug, have an idea for a feature, ideas to reconstruct the code to work better, or anything else, feel free to submit an issue or a pull request.

Using the issue tracker

The issue tracker is the preferred channel for bug reports and features requests.

GitHub issues

Legal Disclaimer

This project is made for educational and ethical testing purposes only. Usage of BFAC for attacking targets without prior mutual consent is illegal. It is the end user's responsibility to obey all applicable local, state and federal laws. Developers assume no liability and are not responsible for any misuse or damage caused by this program.

License

The project is currently licensed under GNU GPLv3.0 License.

GitHub license

Author

Mazin Ahmed

More Repositories

1

secrets-patterns-db

Secrets Patterns DB: The largest open-source Database for detecting secrets, API keys, passwords, tokens, and more.
Python
865
star
2

Firefox-Security-Toolkit

A tool that transforms Firefox browsers into a penetration testing suite
Shell
473
star
3

shennina

Automating Host Exploitation with AI
Python
433
star
4

struts-pwn

An exploit for Apache Struts CVE-2017-5638
Python
417
star
5

server-status_PWN

A script that monitors and extracts requested URLs and clients connected to the service by exploiting publicly accessible Apache server-status instances.
Python
407
star
6

GithubCloner

A script that clones Github repositories of users and organizations.
Python
381
star
7

tfquery

tfquery: Run SQL queries on your Terraform infrastructure. Query resources and analyze its configuration using a SQL-powered framework.
Python
324
star
8

xless

The Serverless Blind XSS App
JavaScript
316
star
9

struts-pwn_CVE-2018-11776

An exploit for Apache Struts CVE-2018-11776
Python
299
star
10

jwt-pwn

Security Testing Scripts for JWT
Python
288
star
11

struts-pwn_CVE-2017-9805

An exploit for Apache Struts CVE-2017-9805
Python
247
star
12

public

PHP
36
star
13

go-random

🌐 go-random: A fast, clear, and cryptographically-secure random data generator for Golang
Go
27
star
14

whatsapp-chat-parser

WhatsApp Chat Parser
Python
17
star
15

Ubuntu-Desktop-Malware-Vector-Demo

Demo for http://blog.mazinahmed.net/2017/04/using-ubuntu-desktop-as-malware-vector.html
5
star
16

gronpy

Print JSON objects in a "Greppable" output.
Python
4
star
17

trufflehog-clone

Trufflehog v2 Clone
2
star
18

juice-shop

TypeScript
2
star
19

mazinahmed.net

mazinahmed.net
HTML
2
star
20

detect_passive_secrets

JavaScript
1
star