Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nat-418/grimoire
Personal software repository (Codeberg mirror)
https://github.com/nat-418/grimoire
nix packages
Last synced: 13 days ago
JSON representation
Personal software repository (Codeberg mirror)
- Host: GitHub
- URL: https://github.com/nat-418/grimoire
- Owner: nat-418
- License: other
- Created: 2022-10-28T19:26:47.000Z (about 2 years ago)
- Default Branch: trunk
- Last Pushed: 2024-04-29T23:06:29.000Z (8 months ago)
- Last Synced: 2024-11-05T11:36:45.061Z (about 2 months ago)
- Topics: nix, packages
- Language: Go
- Homepage: https://codeberg.org/nat-418/grimoire
- Size: 11.9 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Knock 🚪
![Semantic Versioning 2.0.0]
![Conventional Commits 1.0.0]`knock` is a simple, command-line network reachability tester. I made `knock`
because I found myself using `telnet` to test if I could successfully connect
to remote databases, webservers, and the like fairly often and realized that I
don't actually need all of the features and historical baggage of that
software: I just want to know if I can get from point A to B. `knock` is
designed around this use-case. Other tools like `ncat` do more and better, but
they also bring needless complexity to this task.## Installation
Build from source or [download a pre-built binary].
```bash
$ ./build.tcl
```## Usage
You can call `knock` just like `telnet`:
```bash
$ knock localhost 8080
Failed: connection refused.
```Or with a colon:
```bash
$ knock 192.168.100.1:22
Succeeded.
```Or with option flags:
```bash
$ knock -time 10 -dest example.com -port 8000 -net tcp
Failed: connection timed out after 10 seconds.
```Normally, any problem connecting will be reported to the user
as explicitly as possible. Unlike `telnet`, `knock` will never
prompt the user for interactive input. As soon as a connection
succeeds, `knock` will hang up and report back that success.### Options
| Option | Description |
| ------ | ------------------------------------------------------- |
| -dest | Network destination address or name |
| -net | Network type to use (default `tcp`) |
| -port | Port number to `knock` on destination (default `80`) |
| -time | Time to wait in seconds before giving up (default `15`) |### Networks
Supported network types are `tcp`, `tcp4`, `tcp6`, `udp`, `udp4`, `udp6`,
`ip`, `ip4`, `ip6 `, `unix`, `unixgram`, and `unixpacket`. The network types
with `4` in their name are IPv4-only, and those with `6` are IPv6-only.## Miscellaneous
Knock is open source-software distributed under the 0BSD license.
To report bugs or view source code, see https://codeberg.org/nat-418/knock.[download a pre-built binary]: https://codeberg.org/nat-418/knock/releases/latest
[Conventional Commits 1.0.0]: https://flat.badgen.net/badge/Conventional%20Commits/1.0.0/
[Semantic Versioning 2.0.0]: https://flat.badgen.net/badge/Semantic%20Versioning/2.0.0/