TestimoX

API Reference

Command

Set-CxSmbConfig

Namespace ComputerX.PowerShell
Inputs
System.String
Outputs
ComputerX.Smb.SmbConfigWriter+Result

Sets SMB server/client security configuration (selected fields only).

Examples

Authored help example

Example 1


Set-CxSmbConfig -ServerSigningRequired $true -ClientAllowInsecureGuestAuth $false -RestrictAnonymous 1 -RestartLanmanServer
        

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.

Syntax

Set-CxSmbConfig [-ComputerName <string>] [-AutoShareServer <bool>] [-AutoShareWks <bool>] [-ClientAllowInsecureGuestAuth <bool>] [-ClientSigningEnabled <bool>] [-ClientSigningRequired <bool>] [-EnableLmHosts <bool>] [-EnablePlainTextPassword <bool>] [-EveryoneIncludesAnonymous <bool>] [-LmCompatibilityLevel <int>] [-MergeNullLists] [-NodeType <int>] [-NullSessionPipes <string[]>] [-NullSessionShares <string[]>] [-RestartLanmanServer] [-RestrictAnonymous <int>] [-RestrictAnonymousSam <int>] [-ServerRestrictNullSessAccess <bool>] [-ServerSigningEnabled <bool>] [-ServerSigningRequired <bool>] [-ServerSmb1Enabled <bool>] [-ServerSmb2Enabled <bool>] [<CommonParameters>]
#

Parameters

ComputerName string optionalposition: 0pipeline: true (ByPropertyName)
Target computer(s). Use '.' for local computer or provide DNS names.
AutoShareServer bool optionalposition: namedpipeline: false
Gets or sets the AutoShareServer parameter.
AutoShareWks bool optionalposition: namedpipeline: false
Gets or sets the AutoShareWks parameter.
ClientAllowInsecureGuestAuth bool optionalposition: namedpipeline: false
Gets or sets the ClientAllowInsecureGuestAuth parameter.
ClientSigningEnabled bool optionalposition: namedpipeline: false
Gets or sets the ClientSigningEnabled parameter.
ClientSigningRequired bool optionalposition: namedpipeline: false
Gets or sets the ClientSigningRequired parameter.
EnableLmHosts bool optionalposition: namedpipeline: false
Gets or sets the EnableLmHosts parameter.
EnablePlainTextPassword bool optionalposition: namedpipeline: false
Gets or sets the EnablePlainTextPassword parameter.
EveryoneIncludesAnonymous bool optionalposition: namedpipeline: false
Gets or sets the EveryoneIncludesAnonymous parameter.
LmCompatibilityLevel int optionalposition: namedpipeline: false
Gets or sets the LmCompatibilityLevel parameter.
MergeNullLists SwitchParameter optionalposition: namedpipeline: false
Gets or sets the MergeNullLists parameter.
NodeType int optionalposition: namedpipeline: false
Gets or sets the NodeType parameter.
NullSessionPipes string[] optionalposition: namedpipeline: false
Null session named pipes to apply (if provided).
NullSessionShares string[] optionalposition: namedpipeline: false
Null session shares to apply (if provided).
RestartLanmanServer SwitchParameter optionalposition: namedpipeline: false
Gets or sets the RestartLanmanServer parameter.
RestrictAnonymous int optionalposition: namedpipeline: false
Gets or sets the RestrictAnonymous parameter.
RestrictAnonymousSam int optionalposition: namedpipeline: false
Gets or sets the RestrictAnonymousSam parameter.
ServerRestrictNullSessAccess bool optionalposition: namedpipeline: false
Gets or sets the ServerRestrictNullSessAccess parameter.
ServerSigningEnabled bool optionalposition: namedpipeline: false
Gets or sets the ServerSigningEnabled parameter.
ServerSigningRequired bool optionalposition: namedpipeline: false
Gets or sets the ServerSigningRequired parameter.
ServerSmb1Enabled bool optionalposition: namedpipeline: false
Gets or sets the ServerSmb1Enabled parameter.
ServerSmb2Enabled bool optionalposition: namedpipeline: false
Gets or sets the ServerSmb2Enabled parameter.

Outputs

ComputerX.Smb.SmbConfigWriter+Result