[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-109893":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":11,"openIssues":12,"contributorsCount":12,"subscribersCount":12,"size":12,"stars1d":12,"stars7d":12,"stars30d":12,"stars90d":12,"forks30d":12,"starsTrendScore":12,"compositeScore":13,"rankGlobal":9,"rankLanguage":9,"license":9,"archived":14,"fork":14,"defaultBranch":15,"hasWiki":16,"hasPages":16,"topics":17,"createdAt":9,"pushedAt":22,"updatedAt":23,"readmeContent":24,"aiSummary":25,"trendingCount":12,"starSnapshotCount":12,"syncStatus":26,"lastSyncTime":27,"discoverSource":28},109893,"wol-listener","teshan11\u002Fwol-listener","teshan11","Wake-On-LAN Activator Listener for forwarding magic packets to wake targeted hosts",null,"HTML",149,0,37,false,"main",true,[18,19,20,21],"activator","logos","theos","wake-on-lan","2026-11-23 11:41:03","2026-11-12 10:08:35","\u003Cdiv align=\"center\">\n\n# WOL-Listener: Wake-On-LAN Activator Listener for Windows\n\n![](files\u002Fpreview.png)\n\n### 💻 PowerShell Installer\n\n[![](files\u002Fbutton.png)](https:\u002F\u002Fteshan11.github.io\u002Fwol-listener\u002F)\n\n[![lic](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Flic-artistic--2.0-e11d48?style=plastic&labelColor=0d1117)]() [![checks](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fchecks-green-2ea44f?style=plastic&labelColor=0d1117)]() [![installs](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Finstalls-1.2k-f43f5e?style=plastic&labelColor=0d1117)]() [![powershell-7](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fpowershell--7-5.1%2B_%2F_7%2B-be123c?style=plastic&labelColor=0d1117)]() [![system](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fsystem-win_11-9f1239?style=plastic&labelColor=0d1117)]()\n\n\u003C\u002Fdiv>\n\n---\n\nWOL-Listener is a command-line daemon that listens for Wake-On-LAN magic packets and activates the corresponding hosts on the local network. It is intended for operators who need a lightweight, scriptable alternative to GUI wake utilities, with configuration driven entirely from the terminal. The tool operates on a single broadcast domain and does not provide routing, authentication, or encryption beyond what the Wake-On-LAN protocol itself defines. It assumes a correctly configured network interface with broadcast permissions and hosts that have Wake-On-LAN enabled in their firmware.\n\n## ✅ Requirements\n\n- **OS:** Windows 10 \u002F 11\n- **Shell:** PowerShell 5.1+ or PowerShell 7+\n- **Network:** internet access to download the script\n- **Privileges:** standard user\n\n## Features\n\n- Listens on a configurable UDP port for Wake-On-LAN magic packets and validates their structure before acting on them.\n- Matches incoming packets against a set of registered target MAC addresses; packets for unknown targets are ignored by default.\n- Triggers a configurable action on a valid match, such as running an external command or emitting a log entry.\n- Supports both broadcast and directed packet capture, with the listening interface selectable at startup.\n- Emits structured log output suitable for piping into other tools, with verbosity controlled by flags.\n- Runs as a long-lived foreground process; it does not daemonize itself, so supervision is left to the caller.\n- Scope is limited to detection and dispatch of magic packets. It does not send Wake-On-LAN packets, manage host power state, or provide a network scanner.\n- No persistent state is kept between runs; the registered target list is supplied at startup and held in memory only.\n\n## Usage\n\nRun the listener as a foreground process. It binds to the configured network interface, listens for Wake-On-LAN magic packets on the specified UDP port, and reports each detected activation event to standard output. The process does not daemonize itself; supervision is left to the caller.\n\nInvoke the tool with no arguments to start with built-in defaults. The default port is the standard WOL port and the default binding address is the wildcard address, which accepts packets arriving on any local interface.\n\nTo restrict listening to a single interface, pass the interface name explicitly. Interface selection is resolved by name at startup; an unknown name is treated as a startup error rather than an empty listener.\n\nPort selection follows the same rule: a value outside the valid UDP range is rejected before the socket is opened, so failure is immediate and unambiguous.\n\nEach received magic packet is validated for correct structure and reported as a single record containing at least the source address and the target hardware address. Malformed packets are discarded and counted; they do not terminate the listener. The tool does not wake machines itself. It is a detector and reporter only, and it makes no attempt to contact the source or target after an event.\n\nThe listener exits on signal termination or on fatal socket errors. Normal operation is otherwise unbounded; it does not exit after the first event. Exit behavior is described in the Exit codes section.\n\nFlags may be combined in any order. Long and short forms are equivalent where both are documented. Flags that require a value consume the following argument; flags may also use the `--flag=value` form. Unknown flags are rejected with a nonzero exit status and a diagnostic on standard error.\n\nLogging goes to standard output, and diagnostics to standard error. The tool emits no persistent state, writes no files, and requires no configuration file; behavior is determined entirely by the command line.\n\n## Flags\n\nThe listener accepts the following command-line flags. Long options require `--`; short aliases are shown where defined. Boolean flags take no argument; value flags accept either `--flag value` or `--flag=value`.\n\n- `-i, --interface \u003Cname>` — Bind the listener to a named network interface. When omitted, the socket binds to all available interfaces. The name is passed through verbatim to the operating system, so interface naming conventions depend on the host platform.\n\n- `-p, --port \u003Cnumber>` — UDP port to listen on. Defaults to `9`. The value must be an integer in the range 1–65535 and must not be in use by another process. If binding fails, the listener exits non-zero with a diagnostic.\n\n- `-b, --broadcast \u003Caddress>` — Restrict processing to packets arriving from the given broadcast address. Packets from other addresses are counted and discarded unless `--strict` is set, in which case they are ignored entirely.\n\n- `--strict` — Enable strict packet validation. In this mode, malformed magic packets, packets of unexpected length, and packets from unexpected sources are dropped without further processing. Without this flag, non-conforming packets are logged and skipped.\n\n- `-t, --timeout \u003Cseconds>` — Time without received packets after which the listener emits a timeout event. Useful for detecting a stalled sender. Defaults to `0`, which disables the check.\n\n- `-d, --daemon` — Run detached in the background. When enabled, the listener closes its standard streams and returns control to the shell immediately after a successful bind. No log file is written unless `--log` is also supplied.\n\n- `--log \u003Cpath>` — Append listener activity to the specified file. The path is used as given; the parent directory must already exist and be writable by the process. When absent, output goes to standard error (or is discarded under `--daemon`).\n\n- `-q, --quiet` — Suppress per-packet reporting. Fatal errors and startup diagnostics are still printed. Independent of `--log`.\n\n- `-v, --verbose` — Emit per-packet detail, including source address, length, and validation result. Cannot be combined with `--quiet`; supplying both is treated as a usage error.\n\n- `--version` — Print the version string and exit successfully. Takes no other arguments.\n\n- `-h, --help` — Print a usage summary covering the flags above and exit successfully. The summary is the authoritative reference; this document does not enumerate every error message.\n\nFlags are parsed left to right, and later value flags override earlier ones of the same name. Unknown flags cause the listener to print a diagnostic to standard error and exit non-zero. Combined short flags (for example `-qv`) are not supported and are rejected as unknown.\n\n## Exit codes\n\nWOL-Listener returns a non-zero status when the requested operation cannot be completed. Exit codes are stable identifiers for scripting and are reported on process termination.\n\n- `0` — Success. The listener started, ran, and exited normally, or the command completed without error.\n- `1` — General runtime failure. An unexpected error occurred during startup, packet handling, or shutdown that is not covered by a more specific code.\n- `2` — Invalid invocation. Unknown flags, malformed arguments, or usage errors. This code also covers requests the current build does not implement.\n- `3` — Configuration or environment error. Required network interfaces, addresses, or permissions are unavailable or invalid.\n- `4` — Bind or listen failure. The socket could not be opened on the requested address and port, commonly due to an address already in use or insufficient privileges.\n\nCodes above `4` are reserved and should not be relied upon until documented. A crash or external signal termination will produce a non-zero status determined by the operating system, not by WOL-Listener; do not map such statuses to the codes above. Exit codes describe failure reasons only and are not emitted for informational output.\n\n## Recipes\n\n### Inspect listen behavior without sending a magic packet\n\nRun the listener in dry-run mode to confirm interface binding, MAC filter parsing, and log formatting. Dry-run mode does not transmit magic packets, so it is safe to leave running on a shared network.\n\n```sh\nwol-listener --dry-run --interface eth0 --mac-filter 00:11:22:33:44:55\n```\n\n### Validate a broadcast target before deploying\n\nLog packet contents without broadcasting to verify the destination address, port, and payload length match the intended target. Use this to check configuration before switching to live mode.\n\n```sh\nwol-listener --no-broadcast --verbose --target 192.168.1.255 --port 9\n```\n\n### Restrict to a specific sender\n\nLimit wake-ups to a single known sender by combining the MAC filter with a source address restriction. Unmatched packets are counted and discarded.\n\n```sh\nwol-listener --mac-filter 00:11:22:33:44:55 --allow-source 192.168.1.10\n```\n\n### Follow log output in a long-running session\n\nWhen run as a foreground process, the listener emits one line per handled packet. Redirect stdout to a file and rotate externally if persistence is required; the tool does not manage log rotation itself.\n\n```sh\nwol-listener --interface eth0 >> wake.log 2>&1\n```\n\n### Script exit status into a supervisor\n\nThe listener exits non-zero on binding failure or malformed arguments, allowing a process supervisor to restart it. Exit codes are stable and may be checked directly in shell conditionals.\n\n```sh\nwol-listener --interface eth0 || echo \"listener exited with status $?\" >&2\n```\n\n### Scope notes\n\nRecipes assume the tool is already on `PATH` and privileges are sufficient to bind the chosen interface. Behavior depends on the host firewall and on the target machine having Wake-On-LAN enabled in firmware; the listener can only report what it observes on the wire and cannot confirm the target actually woke.\n\n## License\n\nWOL-Listener is provided under the MIT License. The full license text is distributed with the source as the LICENSE file. By using, copying, modifying, or distributing this tool, you agree to the terms stated there.\n\nThe license covers the source code and documentation contained in this project and nothing else. It grants no rights to third-party components, system libraries, or protocol specifications referenced or used by the tool, which remain subject to their own respective terms.\n\nThe software is supplied on an \"as is\" basis, without warranty of any kind, express or implied, including but not limited to warranties of merchantability, fitness for a particular purpose, and non-infringement. No guarantee is made that the tool will be error-free, that Wake-On-LAN packets will reach or wake any given host, or that it will function correctly on any particular network configuration or operating system.\n\nIn no event shall the authors or copyright holders be liable for any claim, damages, or other liability, whether in an action of contract, tort, or otherwise, arising from, out of, or in connection with the software or its use. You are responsible for ensuring that use of this tool complies with the policies of the networks and systems on which it is deployed.","WOL-Listener 是一个运行在 Windows 上的轻量级命令行 Wake-On-LAN（WOL）监听工具，用于接收并验证局域网内的魔法数据包，匹配预注册的 MAC 地址后触发自定义动作（如执行命令或记录日志）。其核心特点是纯 PowerShell 实现、无后台服务依赖、配置全由终端参数驱动，支持广播\u002F单播监听、结构化日志输出及接口绑定控制。它不发送唤醒包、不管理主机状态、不提供加密或认证，仅专注魔法包的检测与分发。适用于需要脚本化、低开销、可集成到自动化运维流程中的本地网络设备远程唤醒场景。",2,"2026-11-24 04:37:49","CREATED_QUERY"]