CreateDirectory
Task to create a directory on SMB share.
Task version: 2.4.0
Required Frends version: 5.7+
Required .NET version: 8.0
Compatible Agents: Crossplatform
Task Parameters
DirectoryPath : String
Full path to the directory (relative to the share) we want to create. If a folder already exists, nothing happens.
Default: -
Example: root\folder\newFolder
Server : String
SMB server address or hostname.
Default: -
Example: 127.0.0.1
Share : String
SMB share name to connect to.
Default: -
Example: testShare
Username : String
Username for SMB authentication.
This needs to be of format domain\username
Default: -
Example: WORKGROUP\Administrator
🗝Password : String
Password for the SMB credentials.
Default: -
Example: Password123
OperatingSystem : Os
Defines the operating system of the SMB server.
Options used to determine correct path separator to use.
Possible values:
Windows: Defines the operating system of the SMB server.
Options used to determine correct path separator to use.
Linux: Defines the operating system of the SMB server.
Options used to determine correct path separator to use.
Default: Linux
Example: Linux
AuthenticationMode : AuthenticationMode
Authentication mechanism to use when connecting to the SMB server.
Kerberos requires network access to a KDC and a registered SPN (cifs/servername)
for the target server in Active Directory.
Possible values:
Ntlm: NTLM authentication protocol.Kerberos: Kerberos authentication protocol.
Default: Ntlm
Example: Ntlm
KerberosServerName : String
Hostname used to build the Kerberos SPN (cifs/hostname) when AuthenticationMode is Kerberos.
Falls back to Server when not set. Only needed when the address used for the TCP
connection differs from the server's registered Kerberos identity - e.g.
where you connect via a mapped IP/port but the AD-registered name is something else.
Default: -
Example: DC1.test.local
KdcAddress : String
Optional explicit KDC address (host or host:port) for Kerberos authentication.
Use when DNS SRV discovery is unavailable.
If empty, KDC will be discovered via DNS SRV records for the realm.
Default: -
Example: kdc.company.com:88
ThrowErrorOnFailure : Boolean
Whether to throw an error on failure.
Default: True
Example: false
ErrorMessageOnFailure : String
Overrides the error message on failure.
Default: -
Example: Custom error message
Task Result
Success : Boolean
Indicates if the task completed successfully.
Example: true
FullUncPath : PathString
Full path of the created directory.
Example: \host\share\dir\newDir
FullUncPath.Value : String
Gets or sets the normalized path value.
Example: folder\file.txt
Error : Error
Error that occurred during task execution.
Example: object { string Message, Exception AdditionalInfo }
Error.Message : String
Summary of the error.
Example: Unable to create a directory.
Error.AdditionalInfo : Exception
Additional information about the error.
Example: object { Exception AdditionalInfo }
Task Changelog
Changelog for Task Frends.Smb.CreateDirectory.
[2.4.0] - 2026-07-27
Added
Added Kerberos authentication support for SMB connections
New
Connection.AuthenticationModeproperty withNtlm(default) andKerberosoptionsNew
Connection.KerberosServerNameproperty for specifying the Kerberos SPN hostname when it differs from the TCP connection addressNew
Connection.KdcAddressproperty for explicit KDC address when DNS SRV discovery is unavailableKerberosNetAuthenticationClientinternally handles TGT acquisition, service ticket retrieval, and GSS-API token generation using the Kerberos.NET library
[2.3.0] - 2026-07-20
Fixed
Optimized SMB file handling: fixed lingering locks and adjusted access permissions to prevent sharing violations.
[2.2.0] - 2026-06-26
Changed
Username parsing: now accepts a username without a domain instead of throwing an error.
Server connection: removed manual DNS resolve; connects using the raw server address string.
[2.1.0] - 2026-04-23
Fixed
Input parameters treated as normal string instead of PathString type.
[2.0.0] - 2026-04-08
Added
New connection parameters that defined what servers Operating System.
[Breaking Change] Introduce PathString type that will represent paths with OS specific separators.
[1.0.0] - 2025-11-13
Added
Initial implementation
Last updated
Was this helpful?

