Skip to content

Commit

Permalink
windows: add flags for GetAdaptersAddresses
Browse files Browse the repository at this point in the history
This commit adds all missing flags for GetAdaptersAddresses.

Change-Id: I874623b6ac77af4ced49205493258e118a4f1b26
GitHub-Last-Rev: 384c92a
GitHub-Pull-Request: #203
Reviewed-on: https://go-review.googlesource.com/c/sys/+/597915
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Than McIntosh <thanm@google.com>
  • Loading branch information
database64128 authored and alexbrainman committed Jul 17, 2024
1 parent 0c18c88 commit 0eac9b5
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion windows/types_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -2003,7 +2003,21 @@ const (
MOVEFILE_FAIL_IF_NOT_TRACKABLE = 0x20
)

const GAA_FLAG_INCLUDE_PREFIX = 0x00000010
// Flags for GetAdaptersAddresses, see
// https://learn.microsoft.com/en-us/windows/win32/api/iphlpapi/nf-iphlpapi-getadaptersaddresses.
const (
GAA_FLAG_SKIP_UNICAST = 0x1
GAA_FLAG_SKIP_ANYCAST = 0x2
GAA_FLAG_SKIP_MULTICAST = 0x4
GAA_FLAG_SKIP_DNS_SERVER = 0x8
GAA_FLAG_INCLUDE_PREFIX = 0x10
GAA_FLAG_SKIP_FRIENDLY_NAME = 0x20
GAA_FLAG_INCLUDE_WINS_INFO = 0x40
GAA_FLAG_INCLUDE_GATEWAYS = 0x80
GAA_FLAG_INCLUDE_ALL_INTERFACES = 0x100
GAA_FLAG_INCLUDE_ALL_COMPARTMENTS = 0x200
GAA_FLAG_INCLUDE_TUNNEL_BINDINGORDER = 0x400
)

const (
IF_TYPE_OTHER = 1
Expand Down

0 comments on commit 0eac9b5

Please sign in to comment.