mirror of
https://github.com/2dust/v2rayN.git
synced 2026-11-05 12:04:59 +03:00
This reverts commit f347fe1c03.
This commit is contained in:
@@ -54,12 +54,12 @@ internal static class WindowsUtils
|
|||||||
|
|
||||||
public static async Task RemoveTunDevice()
|
public static async Task RemoveTunDevice()
|
||||||
{
|
{
|
||||||
var tunNameList = new List<string> { "singbox_tun", "xray_tun" };
|
var tunNameList = new List<string> { "wintunsingbox_tun", "xray_tun" };
|
||||||
foreach (var tunName in tunNameList)
|
foreach (var tunName in tunNameList)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var sum = MD5.HashData(Encoding.UTF8.GetBytes($"wintun{tunName}"));
|
var sum = MD5.HashData(Encoding.UTF8.GetBytes(tunName));
|
||||||
var guid = new Guid(sum);
|
var guid = new Guid(sum);
|
||||||
var pnpUtilPath = @"C:\Windows\System32\pnputil.exe";
|
var pnpUtilPath = @"C:\Windows\System32\pnputil.exe";
|
||||||
var arg = $$""" /remove-device "SWD\Wintun\{{{guid}}}" """;
|
var arg = $$""" /remove-device "SWD\Wintun\{{{guid}}}" """;
|
||||||
|
|||||||
Reference in New Issue
Block a user