|
| 1 | +--- |
| 2 | +title: Testing Manual |
| 3 | +--- |
| 4 | + |
| 5 | +# Historical Fingerprinter Testing Manual |
| 6 | + |
| 7 | +This manual provides instructions for testing the Historical Fingerprinter challenge using Docker and Docker Compose. |
| 8 | + |
| 9 | +## Overview |
| 10 | + |
| 11 | +- Tests are designed to evaluate the effectiveness of your detection scripts against the Historical Fingerprinter challenge. |
| 12 | +- Uses Docker for easy submission and testing |
| 13 | + |
| 14 | +## Quick Start Guide |
| 15 | + |
| 16 | +### Prerequisites |
| 17 | + |
| 18 | +- Docker |
| 19 | +- Docker Compose |
| 20 | + |
| 21 | +### Step 0: Clone the Repository [skip if you cloned already] |
| 22 | + |
| 23 | +```bash |
| 24 | +git clone git@github.com:RedTeamSubnet/historical-fingerprinter-challenge.git historical_fingerprinter |
| 25 | +cd historical_fingerprinter |
| 26 | +``` |
| 27 | + |
| 28 | +### Step 1: Provide Your all Scripts |
| 29 | + |
| 30 | +- Paste all of your all 3 scripts into **src/hfp_challenge/challenge/fingerprinter/src/submissions** folder with matching names. |
| 31 | + |
| 32 | +### Step 2: Update Configuration Files |
| 33 | + |
| 34 | +```bash |
| 35 | +cp .env.example .env |
| 36 | +cp ./templates/compose/compose.override.dev.yml ./compose.override.yml |
| 37 | +``` |
| 38 | + |
| 39 | +### Step 3: Setting up environmental variables |
| 40 | + |
| 41 | +- Change `HFP_CHALLENGE_API_KEY` with your own preferred API key. You can use any string as API key, but make sure to update it in your detection scripts as well. |
| 42 | + |
| 43 | +### Step 4: Start the Challenge Server |
| 44 | + |
| 45 | +```bash |
| 46 | +docker compose up -d challenge-api |
| 47 | +``` |
| 48 | + |
| 49 | +### Step 4: Test Your Bot |
| 50 | + |
| 51 | +- Visit <https://localhost:10001/docs> |
| 52 | +- Authenticate using provided authentication API that you put into the `.env` with `HFP_CHALLENGE_API_KEY` variable. |
| 53 | +  |
| 54 | +- Test your detection files by running the `/score` endpoint |
| 55 | +- if you see the warning log(like `Please visit endpoint <URI> to complete human verification for the task.`) then open given uri in log in your browser to complete human verification in your side. |
| 56 | + |
| 57 | +## Important Notes |
| 58 | + |
| 59 | +- The server runs on port 10001 by default |
| 60 | +- Make sure port 10001 is available on your system |
| 61 | +- All interactions are logged for analysis. Miners can check logs by running `docker compose logs -f` |
| 62 | +- All commands must be executed from challenge's root directory. |
| 63 | +- If you want score justification, you can check all results with `results` endpoint after running the `score` endpoint. |
| 64 | + |
| 65 | +## Troubleshooting |
| 66 | + |
| 67 | +If you encounter issues: |
| 68 | + |
| 69 | +1. Check if Docker is running |
| 70 | +2. Verify port 10001 is not in use |
| 71 | +3. Check Docker logs using `docker compose logs` |
| 72 | +4. Ensure you have proper permissions to run Docker commands |
0 commit comments