For the complete documentation index, see llms.txt. This page is also available as Markdown.

MoveDirectory

Task to move a directory inside the SMB share.

Task version: 2.4.0

Required Frends version: 5.7+

Required .NET version: 8.0

Compatible Agents: Crossplatform

Task Parameters

Name
Description

SourcePath : String

Source path relative to the share where directory will be moved from.

Default: - Example: documents/reports

TargetPath : String

Target path relative to the share where directory will be moved to.

Default: - Example: backup/reports

Name
Description

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: 2 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: 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.

  • Kerberos: 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.

Default: 0 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

Name
Description

IfTargetDirectoryExists : DirectoryExistsAction

Specifies the action to take when a directory with the same name already exists in the target location.

Possible values:

  • Throw: Specifies the action to take when a directory with the same name already exists in the target location.

  • Overwrite: Specifies the action to take when a directory with the same name already exists in the target location.

  • Rename: Specifies the action to take when a directory with the same name already exists in the target location.

Default: 0 Example: Throw

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

Name
Description

Success : Boolean

Indicates if the task completed successfully. Example: true

SourcePath : PathString

The original path of the directory that was moved, relative to the share. Example: Projects\OldApp

TargetPath : PathString

The new path of the directory after the move operation, relative to the share. Example: Archive\OldApp

Error : Error

Error that occurred during task execution. Example: object { string Message, Exception AdditionalInfo }

Task Changelog

Changelog for Task Frends.Smb.MoveDirectory.

[2.4.0] - 2026-07-27

Added

  • Added Kerberos authentication support for SMB connections

    • New Connection.AuthenticationMode property with Ntlm (default) and Kerberos options

    • New Connection.KerberosServerName property for specifying the Kerberos SPN hostname when it differs from the TCP connection address

    • New Connection.KdcAddress property for explicit KDC address when DNS SRV discovery is unavailable

    • KerberosNetAuthenticationClient internally 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.

[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-12-03

Added

  • Initial implementation

Last updated

Was this helpful?