dchristl / macless-haystack

Create your own AirTag with OpenHaystack, but without the need to own an Apple device
GNU General Public License v3.0
266 stars 48 forks source link
esp32 findmy openhaystack

Macless-Haystack

last commit Docker Hub Docker Pulls

This project tries to unify several projects for an easy-to-use and easy-to-setup custom FindMy network. The goal is to run a FindMy network without the need to own a real Mac or virtual Mac. Also you don't have to install the mail plugin or openhaystack itself. (As needed by the original OpenHaystack project).

Table of Contents

Setup

In this section, you will find a step-by-step guide on how to set up your own Macless-Haystack network.

1. Prerequisites ## Prerequisites - [Docker](https://www.docker.com/) installed - [Python3](https://www.python.org/) and [pip3](https://pypi.org/project/pip/) installed - Apple-ID with 2FA enabled. Only sms/text message as second factor is supported! ---
2. Hardware setup ## Hardware setup 1. Head over to the [releases](https://github.com/dchristl/macless-haystack/releases/latest) section and download `generate_keys.py` and your needed firmware (ESP32 or NRF5x) zip file. 2. Execute the `generate_keys.py` script to generate your keypair. (Note: dependency `cryptography` is needed. Install it with `pip install cryptography`) 3. Unzip the firmware and flash it to your device (see [Install ESP32-firmware with your key](firmware/ESP32/README.md) or [Install NRF5x-firmware with your key](firmware/nrf5x/README.md)) ###### Note: In general, any OpenHaystack-compatible device or its firmware is also compatible with Macless-Haystack (i.e. [the ST17H66](https://github.com/biemster/FindMy/tree/main/Lenze_ST17H66)). Typically, only the Base64-encoded advertisement key is required, which can be found in the .keys file after key generation ---
3. Server setup ## Server setup 1. Create a new docker network ```bash docker network create mh-network ``` 2. Install [Anisette Server](https://github.com/Dadoum/anisette-v3-server): ```bash docker run -d --restart always --name anisette -p 6969:6969 --volume anisette-v3_data:/home/Alcoholic/.config/anisette-v3/lib/ --network mh-network dadoum/anisette-v3-server ``` 3. Start and set up your Macless Haystack endpoint in interactive mode: ```bash docker run -it --restart unless-stopped --name macless-haystack -p 6176:6176 --volume mh_data:/app/endpoint/data --network mh-network christld/macless-haystack ``` ###### You will be asked for your Apple-ID, password and your 2FA. If you see `serving at port 6176 over HTTP` you have all set up correctly 4. Restart your server now in background by restarting it in an other terminal ```bash docker restart macless-haystack ``` ---
4. Frontend setup ## Frontend setup You can either use the frontend provided by GitHub, host the webserver for yourself or use the Android application - *Optional*: Mobile: Install application - *Optional*: Host: Browse to [Github Page](https://dchristl.github.io/macless-haystack/) (s. [Notes on SSL usage](FAQ.md#how-can-i-use-ssl-if-the-endpoint-runs-on-another-machine-than-the-ui)) - Import PREFIX_devices.json to your application - If you run the frontend not on the same machine as your endpoint, you have to configure your Url in the settings ---

Problems / Issues / Questions

If you have any problems, issues or questions, please check the FAQ first. If this doesn't help you, create a new issue.

Included projects and changes

Included projects are (Credits goes to them for the hard work):

Screenshots

Android App ### Android ![Dashboard](images/history_mobile.png) ![Dashboard](images/history_mobile_2.png) ![Dashboard](images/accessories_mobile.png) ![Dashboard](images/settings_mobile.png)
Website ### Web ![Dashboard](images/history_web.png) ![Dashboard](images/history_web_light.png) ![Dashboard](images/accessories_web.png)

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License: GPL v3

Disclaimer

This repository is for research purposes only, the use of this code is your responsibility.

I take NO responsibility and/or liability for how you choose to use any of the source code available here. By using any of the files available in this repository, you understand that you are AGREEING TO USE AT YOUR OWN RISK. Once again, ALL files available here are for EDUCATION and/or RESEARCH purposes ONLY.