Giter VIP home page Giter VIP logo

proxy-request-checker's Introduction

Proxy Checker in Go

Check if your network or proxy are working as expected, by checking the status code of a request to a website.

Getting Started

Prerequisites

Configuration

The config/links/links-config.json file contains the proxies to be checked.

[
  {
    "url": "https://xxx.xxx.xxx.xxx:xxxx",
    "expectedStatus": 200
  }
]

Note: Make sure to create the links-config.json file, based on the links-config.example.json file, if it does not exist.


The .env file contains the configuration for the proxy checker. The format is as follows, make sure to create a .env file, based on the .env.example file, if it does not exist.

Note: Find more information about the configuration in the docs/configuration.md file.

Usage

Go Run

To run the proxy checker on the fly, run the following command:

/projects/proxy-request-checker >
$ go run cmd/main.go

Binary

To run the proxy checker as a binary, run the following commands:

/projects/proxy-request-checker >
$ go build -o bin/proxy-checker cmd/main.go
/projects/proxy-request-checker >
$ bin/proxy-checker

Note: Run the binary on the project root directory to avoid any issues with the config files, that might not be found.

The report is saved to the reports folder by default.

Known Issues

  • If running the binary, the report is not saved to the specified file path, also the links.json file is not found, if the binary isn't run from the project root directory. #3

Contributing

I welcome contributions from everyone. Before you get started, please take a moment to review the guidelines.

Branches

This project uses the following branches:

  • master - The main branch. This branch is used for production releases.
  • develop - The development branch. This branch is used for development and testing.

Commit Messages

When you commit, make sure to follow the Contributing Guide for commit messages. This will help keep the commit messages clean and consistent across the project. If you don't follow the guide, your pull request will be rejected.

License

This project is licensed under the MIT license. By contributing to this project, you agree that your contributions will be released under the same license. Also, you agree to the Contributor Covenant Code of Conduct and Developer Certificate of Origin.

Disclaimer

This project is for educational purposes only. I am not responsible for any misuse of this project

proxy-request-checker's People

Contributors

danieljancar avatar dependabot[bot] avatar

Stargazers

Raphael avatar

Watchers

Raphael avatar  avatar

proxy-request-checker's Issues

When running the binary, the report is not saved to the specified file path, also the links.json file is not found

Check List

Description

When running the built binary of the program, it can't find the links.json because it's ran from a different path then the project root, also it can't export the report.json.

Steps to Reproduce

Build executable binary from your local project, try to execute from terminal or GUI.

Expected Behavior

Should work as intended when running with go run cmd/main.go

Actual Behavior

Throws error and fails reading/exporting files

Additional Info

Implement proxy redirect handle, when requesting blacklisted url's

Check List

Description

When testing the url's with a proxy, and the proxy redirects to it's proxy error page, I want to be able to read out some configured information out of that html page, and write it to the report. For example the current_user_group, current_category, etc.

Steps to Reproduce

Request a url which is blacklisted by your proxy and you will probably get a 403.

Expected Behavior

Incase the proxy notices an invalid or unallowed url and redirects to it's reporting/feedback page, I want to grab some information about that page, like f.x category, etc, using the DOM api. The most common case is, the requested url returning the proxies policy response through that requested url.

Actual Behavior

None

Additional Info

Make sure to read the response of the requested but forbidden url. Will normally contain some static html code!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.