Skip to content

Include hidden adapters by default? #499

@gaelicWizard

Description

@gaelicWizard

Details of the scenario you tried and the problem that is occurring

We have a need to configure a setting on a hidden network adapter, easily enough handled by adding -IncludeHidden to *-NetAdapter et al.

Verbose logs showing the problem

Suggested solution to the issue

Options:
1: add IncludeHidden parameter to most of the resources in NetworkingDsc, which in turn passes -IncludeHidden to the appropriate cmdlets. I started #495 on this already, but then @PlagueHO suggested a much simpler solution:
2. Add -IncludeHidden to all the cmdlets, anyways.

My vote is for option 2 with one exception: add IncludeHidden parameter to NetAdapterName resource. All other resources key off of Name/InterfaceAlias so including hidden adapters when searching seems like it wouldn't break anything: the unique name is already specified. But, for NetAdapterName the key is Description so adding -IncludeHidden could potentially increase the search space unexpectedly if wildcards are used.

The DSC configuration that is used to reproduce the issue (as detailed as possible)

# insert configuration here

The operating system the target node is running

OsName : Microsoft Windows 10 Pro for Workstations
OsOperatingSystemSKU : 161
OsArchitecture : 64-bit
WindowsVersion : 2009
WindowsBuildLabEx : 19041.1.amd64fre.vb_release.191206-1406
OsLanguage : en-US
OsMuiLanguages : {en-US}

Version and build of PowerShell the target node is running

Name Value


PSVersion 5.1.19041.906
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.19041.906
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

Version of the DSC module that was used ('dev' if using current dev branch)

8.2.0 NetworkingDsc

Metadata

Metadata

Assignees

No one assigned

    Labels

    discussionThe issue is a discussion.enhancementThe issue is an enhancement request.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions