AutoLock is a Node.js-based automation tool that monitors device/network activity and performs automatic actions like login/logout based on connectivity or inactivity.
- Detects device/network presence using ping
- Automates login/logout actions
- Supports inactivity-based triggers (extendable)
- Lightweight and runs locally
- Easy to customize for different workflows
- Node.js
- JavaScript
pingmodulechild_process(for system commands)
AutoLock/
│── index.js # Main script
│── package.json # Dependencies
│── .gitignore
│── README.md
- Clone the repository:
git clone https://github.com/<your-username>/AutoLock.git
cd AutoLock
- Install dependencies:
npm install
Run the script:
node index.js
The script will:
- Continuously monitor network/device status
- Trigger actions based on conditions (e.g., disconnect → logout)
const res = await ping.promise.probe(ip);
if (res.alive) {
// Device is present → stay logged in
} else {
// Device not found → trigger logout
}- Add GUI dashboard
- Add inactivity timer logic
- Multi-device tracking
- Notification system
Garv Saxena