-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
87 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,7 @@ | |
.idea | ||
v2raya | ||
/kone | ||
/my.ini | ||
/kone.exe | ||
/coverage.txt | ||
cmd/kone/local.ini |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# use kone in Windows | ||
|
||
## 预设条件 | ||
1. 安装 tap-windows (NDIS 6) | ||
[tap-windows](https://community.openvpn.net/openvpn/wiki/GettingTapWindows) | ||
[直接下载](https://build.openvpn.net/downloads/releases/tap-windows-9.21.0.exe) | ||
|
||
2. 配置防火墙,允许kone重定向连接 | ||
使用管理员权限启动 PowerShell,执行`update-firewall-rules.ps1`。 | ||
|
||
>>> 请注意修改 `update-firewall-rules.ps1` 脚本中 Program 参数为kone实际路径。 | ||
3. 编译&运行kone方式同linux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#Requires -Version 3 | ||
#Requires -Modules NetSecurity | ||
|
||
$List = Get-NetFirewallRule -Enabled True -Action Allow -Description 'Work with Kone.' | Where-Object { 'Kone' -eq $_.DisplayName } | ||
$Report = foreach ($Rule in $List) | ||
{ | ||
$Program = (Get-NetFirewallApplicationFilter -AssociatedNetFirewallRule $Rule).Program | ||
|
||
@{ | ||
Profile = $Rule.Profile | ||
Enabled = $Rule.Enabled | ||
Action = $Rule.Action | ||
Protocol = (Get-NetFirewallPortFilter -AssociatedNetFirewallRule $Rule).Protocol | ||
Program = $Program | ||
IsPathValid = Test-Path -PathType Leaf -LiteralPath $Program | ||
} | ||
} | ||
$Report | ||
Pause |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# $Program should direct to execute file | ||
Remove-NetFirewallRule -Description "Work with Kone." -ErrorAction SilentlyContinue | ||
'TCP', 'UDP' | ForEach-Object { | ||
New-NetFirewallRule ` | ||
-DisplayName "Kone" ` | ||
-Profile "Any" ` | ||
-Description "Work with Kone." ` | ||
-Direction Inbound ` | ||
-Protocol $_ ` | ||
-Action Allow ` | ||
-Program "E:\go\github\kone\kone.exe" ` | ||
| Out-Null | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters