SkillPilotAI

PowerShell DirectAccessClientComponents module

DirectAccessClientComponents is the client-side module for DirectAccess: it manages the multisite entry point table, manual site selection and the client user experience. DirectAccess connects a managed laptop to the office network automatically whenever it is outside, without a VPN button.

236.1 Why is it used?

  • Remote laptops reach intranet servers with no user action, and IT can manage them whenever they are online.
  • Multisite: several DA sites (entry points); the client picks the best one, or a user/admin can pin one.
  • 11 cmdlets; New/Set/Remove/Enable need an admin shell.
  • Microsoft now recommends Always On VPN instead of DirectAccess for new deployments.

236.2 How it works

DirectAccess from a hotel
  1. 1.Laptop on hotel Wi-Fi probes the Network Location Server (NLS) over HTTPS

  2. 2.NLS is reachable only inside the office, so the probe fails

  3. 3.Laptop concludes "I am outside"

  4. 4.Office IPv6 traffic goes into an IP-HTTPS tunnel over the Internet

  5. 5.DA server Edge1 ends the IPsec tunnel and forwards to intranet.corp.contoso.com

  6. 6.No click, no VPN for the user

Multisite entry point selection
  1. 1.Company has two DA sites: Redmond and Paris (entry points)

  2. 2.Entry point table reaches the laptop via Group Policy

  3. 3.Laptop in Europe auto-selects Paris (AutomaticallySelected)

  4. 4.For troubleshooting: Enable-DAManualEntryPointSelection -EntryPointName Redmond (ManuallySelected)

  5. 5.Disable-DAManualEntryPointSelection returns to automatic

Manual selection succeeds only when the laptop is outside the corp network

236.3 Comparison: DirectAccess vs VPN

PointDirectAccessNormal VPN / Always On VPN
Who connectsAutomatic as soon as the laptop is outsideNormal VPN: user clicks connect; Always On VPN: automatic
Inside detectionNLS reachable = inside, tunnel stays offTrusted network detection (Always On VPN)
TransportIPv6 over IP-HTTPS / Teredo / 6to4 + IPsecIKEv2 / SSTP etc.
Status todayLegacyMicrosoft's recommendation for new deployments: Always On VPN

236.4 What was run on Windows (read-only)

PowerShell
Get-Command -Module DirectAccessClientComponents | Measure-ObjectGet-Help Get-DAEntryPointTableItem
Output
$ Get-Command -Module DirectAccessClientComponents | Measure-ObjectCount    : 11$ Get-Help Get-DAEntryPointTableItemNAME    Get-DAEntryPointTableItemSYNTAX    Get-DAEntryPointTableItem [-EntryPointName <string[]>] [-State {NotSelected | AutomaticallySelected | ManuallySelected}] [-PolicyStore <string>] [-CimSession <CimSession[]>] [-ThrottleLimit    Get-DAEntryPointTableItem [-EntryPointName <string[]>] [-State {NotSelected | AutomaticallySelected | ManuallySelected}] [-GPOSession <string>] [-CimSession <CimSession[]>] [-ThrottleLimit <int>]REMARKS    Get-Help cannot find the Help files for this cmdlet on this computer. It is displaying only partial help.
  • No DirectAccess cmdlet was run: even Get-* would show office entry points and servers.
  • Get-DAEntryPointTableItem has two syntax sets: -PolicyStore or -GPOSession; -State values NotSelected | AutomaticallySelected | ManuallySelected.

236.5 Common parameters

ParameterWhat it does
-CimSession / -AsJob / -ThrottleLimitRemote PC / background job / max parallel operations
-WhatIf / -ConfirmOnly show / ask first
-PolicyStoreActiveStore (Get default), "Domain\GPOName", or "GPO:<computer>" (local GPO)
-GPOSessionGroup Policy session; cannot be combined with -PolicyStore

236.6 Get cmdlets

PowerShell
Get-DAClientExperienceConfiguration -PolicyStore "ActiveStore"Get-DAEntryPointTableItem -PolicyStore "ActiveStore" -EntryPointName "Redmond" -State "NotSelected"
  • Client experience: UI on/off, support email etc.; entry point table: sites, IPs, IP-HTTPS profile.
  • -State is deprecated; the docs show no output and these were not run here.

236.7 Manual entry point selection

PowerShell
Enable-DAManualEntryPointSelection -EntryPointName "Redmond"   # works only outside the corp networkDisable-DAManualEntryPointSelection                            # back to automatic site selection

236.8 Managing entry points

PowerShell
New-DAEntryPointTableItem -PolicyStore "GPO:Localhost" -ADSite "Paris" `  -EntryPointRange "2001::/16" -TeredoServerIP "131.107.1.1" `  -EntryPointIPAddress "200::1" -GslbIP "131.107.0.1" -EntryPointName "Paris"
ParameterMeaning
-ADSiteAD DS site (required)
-EntryPointNameSite name (required)
-EntryPointRangeIPv6 range of clients using this entry point
-EntryPointIPAddressIPv6 address of the entry point
-TeredoServerIP / -IPHttpsProfileTeredo server / IP-HTTPS profile
-GslbIPGlobal server load balancing IP
PowerShell
Get-DAEntryPointTableItem -EntryPointName "Redmond" -PolicyStore "Contoso\GPO1" |  Remove-DAEntryPointTableItemRemove-DAEntryPointTableItem -EntryPointName "Redmond" -PolicyStore "Contoso\GPO1"Rename-DAEntryPointTableItem -EntryPointName "Redmond" -NewName "Bellevue" -PolicyStore "Contoso\GPO1"
PowerShell
# docs example writes Set-DAEntryTableItem; the real name is Set-DAEntryPointTableItemSet-DAEntryPointTableItem -EntryPointName "Paris" -GslbIP "131.107.0.1" -PolicyStore "Contoso\GPO1"Reset-DAEntryPointTableItem -GslbIP -EntryPointName "Paris" -PolicyStore "Contoso\GPO1"
  • Set takes the same options as New; Reset with a switch (e.g. -GslbIP, -TeredoServerIP, -IPHttpsProfile) puts only that property back to not configured.
  • -InputObject takes the pipeline object, -PassThru passes the result on.

236.9 Client experience settings

PowerShell
Set-DAClientExperienceConfiguration -PolicyStore "Contoso\GPO1" -UserInterface "False"Reset-DAClientExperienceConfiguration -PolicyStore "Contoso\GPO1" -FriendlyName "Traveling Policy"# block user override of the site:Set-DAClientExperienceConfiguration -ManualEntryPointSelectionAllowed $false
SettingMeaning
-CorporateResourcesConnectivity probes: "HTTP:", "FILE:", "PING:"
-IPsecTunnelEndpoints"Ping: ipaddress" checks of the tunnel endpoints
-FriendlyNameName shown in the UI (up to 15 chars)
-SupportEmailNeeded for logging
-UserInterfaceUI on/off (default True)
-PassiveModeFewer probes (default False)
-PreferLocalNamesAllowedUser may disconnect DirectAccess
-ManualEntryPointSelectionAllowedUser may pick a site (default True)
-GslbFqdn / -ForceTunnelingMultisite FQDN / Enabled, Disabled (default), Default
-CustomCommandsAdmin commands added to logs
  • Reset-DAClientExperienceConfiguration has a switch per property; these settings can also come from an ADMX file in Group Policy.

236.10 Common mistakes

  • Treating DirectAccess as a normal VPN with a connect button: it is automatic once outside.
  • Expecting a tunnel inside the office: NLS reachable means DirectAccess stays off.
  • Running Enable-DAManualEntryPointSelection inside the corp network: it only works outside.
  • Copying the docs typo Set-DAEntryTableItem instead of Set-DAEntryPointTableItem.
  • Using -PolicyStore and -GPOSession together.

236.11 Interview tips

  • Pin a client to one site: Get-DAEntryPointTableItem -> Enable-DAManualEntryPointSelection -EntryPointName -> later Disable-DAManualEntryPointSelection.
  • Block user override: Set-DAClientExperienceConfiguration -ManualEntryPointSelectionAllowed $false.
  • NLS decides inside vs outside; IP-HTTPS is the usual transport through firewalls.
  • For new deployments mention Always On VPN.