Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/thewhiteh4t/goerli-image-hunt
Detects and extracts images from Goerli Testnet blockchain
https://github.com/thewhiteh4t/goerli-image-hunt
blockchain ctf ethereum goerli image-recognition osint
Last synced: 2 days ago
JSON representation
Detects and extracts images from Goerli Testnet blockchain
- Host: GitHub
- URL: https://github.com/thewhiteh4t/goerli-image-hunt
- Owner: thewhiteh4t
- Created: 2020-12-03T19:04:47.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2021-11-25T20:16:03.000Z (almost 3 years ago)
- Last Synced: 2024-05-02T00:54:34.945Z (7 months ago)
- Topics: blockchain, ctf, ethereum, goerli, image-recognition, osint
- Language: Python
- Homepage:
- Size: 4.88 KB
- Stars: 24
- Watchers: 3
- Forks: 4
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# goerli-image-hunt
I wrote this script for solving a CTF challenge...you may find this code useful in some other similar application like threat hunting, give credits if you choose to use it ;)
**Challenge** : Find and extract an image uploaded on Goerli Testnet Blockchain between a range of dates.
---
### How it works
Transactions in each block contains an **input data** section which contains additional information for transactions. In this challenge hex code of an image was added in this section.
Script fetches block ids for timestamps using EtherScan API then it calculates number of blocks in between these dates and fetches full block information using Goerli Testnet RPC API.
The input data is then tested for a **jpg or png** magic bytes and footers, if a match is found it is saved to a file.---
### Dependencies
```bash
pip3 install requests, web3
```---
### Usage
**Step 1** : Set `Start` and `End` dates in the script
**Note**
* Start and End dates should be in ascending order and in the past, or the script will break, I have not added proper exception handling yet
* **Date Format** : YYYY-MM-DD [ Example : 2020-08-05]**Step 2** : Launch the script and wait until it finds a match, it can take a long time depending on the date range, have patience