forked from metageek-llc/ManagedWifi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
SudoInterface.cs
executable file
·101 lines (78 loc) · 2.23 KB
/
SudoInterface.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
using System;
using System.Net.NetworkInformation;
namespace ManagedWifi
{
class SudoInterface : NetworkInterface
{
#region Fields
private readonly string _desc;
private readonly string _id;
private readonly string _name;
#endregion Fields
#region Properties
public override string Description
{
get { return _desc; }
}
public override string Id
{
get { return _id; }
}
public override bool IsReceiveOnly
{
get { return false; }
}
public override string Name
{
get { return _name; }
}
public override NetworkInterfaceType NetworkInterfaceType
{
get { return NetworkInterfaceType.Wireless80211; }
}
public override OperationalStatus OperationalStatus
{
get { return OperationalStatus.Up; }
}
public override long Speed
{
get { return 0; }
}
public override bool SupportsMulticast
{
get { return false; }
}
#endregion Properties
#region Constructors
public SudoInterface(WlanInterface wlan)
{
_id = wlan.InterfaceGuid.ToString();
_desc = wlan.InterfaceDescription;
}
public SudoInterface(string id, string description, string name)
{
_id = id;
_name = name;
_desc = description;
}
#endregion Constructors
#region Public Methods
public override IPInterfaceProperties GetIPProperties()
{
return null;
}
public override IPv4InterfaceStatistics GetIPv4Statistics()
{
throw new NotImplementedException();
}
public override PhysicalAddress GetPhysicalAddress()
{
return PhysicalAddress.None;
}
public override bool Supports(NetworkInterfaceComponent networkInterfaceComponent)
{
return true;
}
#endregion Public Methods
}
}