This project is a Rust application that automatically handles IIT Mandi captive portal authentication. It runs as a background service that checks for captive portals every 10 seconds, performs automatic login, and sends desktop notifications on successful authentication.
- Rust and Cargo
- Google Chrome
- macOS or Linux
- Clone the repository:
git clone https://github.com/amansikarwar/auto-captive-portal.git
cd auto-captive-portal
- Build the project:
cargo build --release
- Run the setup:
./target/release/acp-script setup
This will:
- Prompt for your LDAP credentials
- Store credentials securely in the system keychain
- Create and start the background service
The service runs as a LaunchAgent and will start automatically on login.
To manually manage the service:
# Start
launchctl load ~/Library/LaunchAgents/com.user.acp.plist
# Stop
launchctl unload ~/Library/LaunchAgents/com.user.acp.plist
# View logs
log show --predicate 'processImagePath contains "acp-script"'
The service runs as a systemd user service.
To manually manage the service:
# Start
systemctl --user start acp
# Stop
systemctl --user stop acp
# View logs
journalctl --user -u acp
This project is licensed under the MIT License - see the LICENSE file for details.