1cattunnel 0.1.2-b.2 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -14,15 +14,33 @@ npm install -g 1cattunnel
14
14
  1cattunnel
15
15
  ```
16
16
 
17
- The package bundles Windows/Linux amd64 client binaries. On first run it creates a writable user config:
17
+ The package bundles Windows/Linux amd64 client binaries. It does not include the enrollment password.
18
+
19
+ On first run it creates a writable user config and the Go client wizard asks for either:
20
+
21
+ - a WebUI bootstrap token; or
22
+ - the enrollment password from the administrator.
23
+
24
+ The entered enrollment password is saved locally so later runs can reconnect automatically. On Windows, choose `Manual custom ports` in the wizard to expose one or more custom TCP/UDP local ports.
25
+
26
+ Config path:
18
27
 
19
28
  - Windows: `%APPDATA%\\1cat-tunnel\\client-windows.json`
20
29
  - Linux: `~/.config/1cat-tunnel/client-linux.json`
21
30
 
22
- Default config connects to `dx.1catai.com:50001` with enrollment password `SuperYMZX666`. The server then issues a per-node runtime credential automatically.
31
+ Linux clients also expose a loopback-only API for submitting blocked IPs to the server:
32
+
33
+ ```bash
34
+ curl -u admin:YOUR_ADMIN_PASSWORD \
35
+ -H "Content-Type: application/json" \
36
+ -d '{"ip":"203.0.113.10","reason":"scan"}' \
37
+ http://127.0.0.1:51888/api/block-ip
38
+ ```
39
+
40
+ The server validates the same WebUI administrator username/password before adding the IP to the persistent blocklist.
23
41
 
24
42
  Use a custom config if needed:
25
43
 
26
44
  ```bash
27
45
  1cattunnel -config ./client-linux.json
28
- ```
46
+ ```
@@ -1,14 +1,14 @@
1
- {
2
- "server_addr": "dx.1catai.com:50001",
3
- "enrollment_password": "SuperYMZX666",
4
- "node_name": "cust-linux-01",
5
- "reconnect_interval_sec": 5,
6
- "presets": [
7
- {
8
- "name": "ssh",
9
- "local_addr": "0.0.0.0:22",
10
- "description": "Expose local SSH",
11
- "protocol": "tcp"
12
- }
13
- ]
14
- }
1
+ {
2
+ "server_addr": "dx.1catai.com:32001",
3
+ "node_name": "cust-linux-01",
4
+ "reconnect_interval_sec": 5,
5
+ "block_ip_api_listen_addr": "127.0.0.1:51888",
6
+ "presets": [
7
+ {
8
+ "name": "ssh",
9
+ "local_addr": "0.0.0.0:22",
10
+ "description": "Expose local SSH",
11
+ "protocol": "tcp"
12
+ }
13
+ ]
14
+ }
@@ -1,14 +1,13 @@
1
- {
2
- "server_addr": "dx.1catai.com:50001",
3
- "enrollment_password": "SuperYMZX666",
4
- "node_name": "cust-win-01",
5
- "reconnect_interval_sec": 5,
6
- "presets": [
7
- {
8
- "name": "rdp",
9
- "local_addr": "127.0.0.1:3389",
10
- "description": "Expose local RDP",
11
- "protocol": "tcp"
12
- }
13
- ]
14
- }
1
+ {
2
+ "server_addr": "dx.1catai.com:32001",
3
+ "node_name": "cust-win-01",
4
+ "reconnect_interval_sec": 5,
5
+ "presets": [
6
+ {
7
+ "name": "rdp",
8
+ "local_addr": "127.0.0.1:3389",
9
+ "description": "Expose local RDP",
10
+ "protocol": "tcp"
11
+ }
12
+ ]
13
+ }
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "1cattunnel",
3
- "version": "0.1.2-b.2",
3
+ "version": "0.2.0",
4
4
  "description": "1Cat Tunnel client with bundled Windows/Linux amd64 binaries",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,
@@ -27,4 +27,4 @@
27
27
  "scripts": {
28
28
  "postinstall": "node scripts/postinstall.js"
29
29
  }
30
- }
30
+ }