Fortinet black logo

Samba v2.0.0

2.0.0
Copy Link
Copy Doc ID 318862eb-6fbe-11ed-8e6d-fa163e15d75b:451

About the connector

Samba is an implementation of the SMB networking protocol and performs Samba operations such as file transfer or authentication over SMB protocol.

This document provides information about the SAMBA Connector, which facilitates automated interactions, with a SAMBA server using FortiSOAR™ playbooks. Add the SAMBA Connector as a step in FortiSOAR™ playbooks and perform automated operations with SAMBA.

Version information

Connector Version: 2.0.0

FortiSOAR™ Version Tested on: 6.4.4-3164 and later

SAMBA Version Tested on: 4.16.4

Authored By: Fortinet

Certified: Yes

Release Notes for version 2.0.0

  • The Samba connector now appears with a new logo
  • Following configuration parameters are now available in the SAMBA Connector version 2.0.0:
    • Domain: Enter a network domain for this parameter. For windows, enter the workgroup
    • NTLM Version: This parameter determines which of the following authentication algorithms should the connector use:
      • NTLMv1
      • NTLMv2
    • Communication Protocol: This parameter specifies which protocol would the connector be using from the following:
      • NetBIOS - Uses port 139
      • TCP/IP - Uses port 445
    • Signing Options: This parameter determines whether the Samba messages will be signed. Users can select one of the following options:
      • NEVER_SIGN - Samba messages are not signed regardless of the remote server's configurations
      • SIGN_WHEN_SUPPORTED - Even if signing is not required, Samba messages are signed when the remote server supports it.
      • SIGN_WHEN_REQUIRED - Samba messages are signed only when the remote server requires signing.

Installing the connector

Use the Content Hub to install the connector. For the detailed procedure to install a connector, click here.
You can also use the following yum command as a root user to install connectors from an SSH session:
yum install cyops-connector-samba

Prerequisites to configuring the connector

  • You must have the URL of the SAMBA server to which you connect and perform automated operations, and credentials to access that server.
  • The FortiSOAR™ server should have outbound connectivity to port 443 on the SAMBA server.

NOTE: If you get ERROR Directory: Make sure to have read/write permission on target location Connector: sambaV2.0.0, it is recommended that you disable SELINUX in your environment.

Minimum Permissions Required

  • Not Applicable

Configuring the connector

For the procedure to configure a connector, click here.

Configuration parameters

In FortiSOAR™, on the Content Hub page, click the Manage tab, and then click the SAMBA connector card. On the connector popup, click the Configurations tab to enter the required configuration details:

NOTE: If you have upgraded your Samba connector from a previous version to v2.0.0, review and reconfigure the configuration settings.

Parameter Description
Server Name Specify the hostname of the Samba server.
Server IP Specify the IP Address of the Samba server.
Domain(Optional) Specify a network domain or a workgroup.
Username Specify a username to access the Samba server.
Password Specify a password to access the Samba server.
Client Name Specify the hostname of the client machine that is connecting to the Samba server.
Samba Share Specify the folder name of the Samba share location.
NTLM Version Select whether you want to use the NTLMv1 or NTLMv2 authentication algorithm for authentication. NTLMv2 is selected by default.
Signing Options Select from the following options whether SMB messages are to be signed.
  • NEVER_SIGN - Samba messages are not signed regardless of the remote server's configurations
  • SIGN_WHEN_SUPPORTED - Even if signing is not required, Samba messages are signed when the remote server supports it.
  • SIGN_WHEN_REQUIRED - Samba messages are signed only when the remote server requires signing.
Default is SIGN_WHEN_REQUIRED.
Communication Protocol Select from the following communication protocols for connecting to the Samba server.
  • NetBIOS - Uses port 139
  • TCP/IP - Uses port 445
Default is NetBIOS

Actions supported by the connector

The following automated operations can be included in playbooks and you can also use the annotations to access operations from FortiSOAR™ release 4.10.0 and onwards:

Function Description Annotation and Category
Upload File Uploads a file to a remote Samba server based on the attachment IRI and folder path you have specified. upload_file
Investigation
Create Directory Creates a folder on a remote Samba server based on the folder path you have specified. create_directory
Investigation
Download File Downloads a file from a remote Samba server based on the file's parent folder path and the file name you have specified. download_file
Investigation
Get Directory Content Provides a list of files and folders for a given location in the Samba server based on the folder name you have specified. get_directory_content
Investigation
Remove Directory Content Removes the content of a folder on a remote Samba server based on the folder path you have specified. delete_directory
Investigation

operation: Upload File

Input parameters

Parameter Description
Attachment IRI Specify the attachment IRI of the file to be uploaded.
Directory Path Specify an upload path, where the file is to be uploaded, relative to the Samba share folder.
Select Action Select an action to perform, if a file already exists, from the following options:
  • Keep existing file
  • Replace existing file

Output

The output contains the following populated JSON schema:
{
"result": ""
}

operation: Create Directory

Input parameters

Parameter Description
Directory Path Specify a folder path where the folder is to be created on the Samba share.

Output

The output contains the following populated JSON schema:
{
"result": ""
}

operation: Download File

Input parameters

Parameter Description
File Directory Path Specify the file's folder path on the Samba share.
File Name Specify the file's name to download from the Samba share.

Output

The output contains the following populated JSON schema:
{
"@context": "",
"@id": "",
"@type": "",
"name": "",
"description": "",
"file": {
"@context": "",
"@id": "",
"@type": "",
"owners": [],
"file": {
"@type": ""
},
"filename": "",
"mimeType": "",
"metadata": "",
"uploadDate": "",
"size": ""
},
"type": "",
"createUser": {
"@id": "",
"@type": "",
"name": "",
"userId": "",
"userType": "",
"avatar": "",
"createUser": "",
"createDate": "",
"modifyUser": "",
"modifyDate": "",
"id": "",
"@settings": ""
},
"createDate": "",
"modifyUser": {
"@id": "",
"@type": "",
"name": "",
"userId": "",
"userType": "",
"avatar": "",
"createUser": "",
"createDate": "",
"modifyUser": "",
"modifyDate": "",
"id": "",
"@settings": ""
},
"modifyDate": "",
"id": ""
}

operation: Get Directory Content

Input parameters

Parameter Description
Directory Name Specify a folder name to get the list of its contents.

Output

The output contains the following populated JSON schema:
{
"result": []
}

operation: Remove Directory Content

Input parameters

Parameter Description
Directory Path Specify a folder path relative to the Samba share folder to remove the contents of that folder.

Output

The output contains the following populated JSON schema:
{
"result": ""
}

Included playbooks

The Sample - SAMBA - 2.0.0 playbook collection comes bundled with the SAMBA connector. These playbooks contain steps using which you can perform all supported actions. You can see bundled playbooks in the Automation > Playbooks section in FortiSOAR™ after importing the SAMBA connector.

  • Create Directory
  • Download File
  • Get Directory Content
  • Remove Directory Content
  • Upload File

Note: If you are planning to use any of the sample playbooks in your environment, ensure that you clone those playbooks and move them to a different collection since the sample playbook collection gets deleted during connector upgrade and delete.

Previous
Next

About the connector

Samba is an implementation of the SMB networking protocol and performs Samba operations such as file transfer or authentication over SMB protocol.

This document provides information about the SAMBA Connector, which facilitates automated interactions, with a SAMBA server using FortiSOAR™ playbooks. Add the SAMBA Connector as a step in FortiSOAR™ playbooks and perform automated operations with SAMBA.

Version information

Connector Version: 2.0.0

FortiSOAR™ Version Tested on: 6.4.4-3164 and later

SAMBA Version Tested on: 4.16.4

Authored By: Fortinet

Certified: Yes

Release Notes for version 2.0.0

Installing the connector

Use the Content Hub to install the connector. For the detailed procedure to install a connector, click here.
You can also use the following yum command as a root user to install connectors from an SSH session:
yum install cyops-connector-samba

Prerequisites to configuring the connector

NOTE: If you get ERROR Directory: Make sure to have read/write permission on target location Connector: sambaV2.0.0, it is recommended that you disable SELINUX in your environment.

Minimum Permissions Required

Configuring the connector

For the procedure to configure a connector, click here.

Configuration parameters

In FortiSOAR™, on the Content Hub page, click the Manage tab, and then click the SAMBA connector card. On the connector popup, click the Configurations tab to enter the required configuration details:

NOTE: If you have upgraded your Samba connector from a previous version to v2.0.0, review and reconfigure the configuration settings.

Parameter Description
Server Name Specify the hostname of the Samba server.
Server IP Specify the IP Address of the Samba server.
Domain(Optional) Specify a network domain or a workgroup.
Username Specify a username to access the Samba server.
Password Specify a password to access the Samba server.
Client Name Specify the hostname of the client machine that is connecting to the Samba server.
Samba Share Specify the folder name of the Samba share location.
NTLM Version Select whether you want to use the NTLMv1 or NTLMv2 authentication algorithm for authentication. NTLMv2 is selected by default.
Signing Options Select from the following options whether SMB messages are to be signed.
  • NEVER_SIGN - Samba messages are not signed regardless of the remote server's configurations
  • SIGN_WHEN_SUPPORTED - Even if signing is not required, Samba messages are signed when the remote server supports it.
  • SIGN_WHEN_REQUIRED - Samba messages are signed only when the remote server requires signing.
Default is SIGN_WHEN_REQUIRED.
Communication Protocol Select from the following communication protocols for connecting to the Samba server.
  • NetBIOS - Uses port 139
  • TCP/IP - Uses port 445
Default is NetBIOS

Actions supported by the connector

The following automated operations can be included in playbooks and you can also use the annotations to access operations from FortiSOAR™ release 4.10.0 and onwards:

Function Description Annotation and Category
Upload File Uploads a file to a remote Samba server based on the attachment IRI and folder path you have specified. upload_file
Investigation
Create Directory Creates a folder on a remote Samba server based on the folder path you have specified. create_directory
Investigation
Download File Downloads a file from a remote Samba server based on the file's parent folder path and the file name you have specified. download_file
Investigation
Get Directory Content Provides a list of files and folders for a given location in the Samba server based on the folder name you have specified. get_directory_content
Investigation
Remove Directory Content Removes the content of a folder on a remote Samba server based on the folder path you have specified. delete_directory
Investigation

operation: Upload File

Input parameters

Parameter Description
Attachment IRI Specify the attachment IRI of the file to be uploaded.
Directory Path Specify an upload path, where the file is to be uploaded, relative to the Samba share folder.
Select Action Select an action to perform, if a file already exists, from the following options:
  • Keep existing file
  • Replace existing file

Output

The output contains the following populated JSON schema:
{
"result": ""
}

operation: Create Directory

Input parameters

Parameter Description
Directory Path Specify a folder path where the folder is to be created on the Samba share.

Output

The output contains the following populated JSON schema:
{
"result": ""
}

operation: Download File

Input parameters

Parameter Description
File Directory Path Specify the file's folder path on the Samba share.
File Name Specify the file's name to download from the Samba share.

Output

The output contains the following populated JSON schema:
{
"@context": "",
"@id": "",
"@type": "",
"name": "",
"description": "",
"file": {
"@context": "",
"@id": "",
"@type": "",
"owners": [],
"file": {
"@type": ""
},
"filename": "",
"mimeType": "",
"metadata": "",
"uploadDate": "",
"size": ""
},
"type": "",
"createUser": {
"@id": "",
"@type": "",
"name": "",
"userId": "",
"userType": "",
"avatar": "",
"createUser": "",
"createDate": "",
"modifyUser": "",
"modifyDate": "",
"id": "",
"@settings": ""
},
"createDate": "",
"modifyUser": {
"@id": "",
"@type": "",
"name": "",
"userId": "",
"userType": "",
"avatar": "",
"createUser": "",
"createDate": "",
"modifyUser": "",
"modifyDate": "",
"id": "",
"@settings": ""
},
"modifyDate": "",
"id": ""
}

operation: Get Directory Content

Input parameters

Parameter Description
Directory Name Specify a folder name to get the list of its contents.

Output

The output contains the following populated JSON schema:
{
"result": []
}

operation: Remove Directory Content

Input parameters

Parameter Description
Directory Path Specify a folder path relative to the Samba share folder to remove the contents of that folder.

Output

The output contains the following populated JSON schema:
{
"result": ""
}

Included playbooks

The Sample - SAMBA - 2.0.0 playbook collection comes bundled with the SAMBA connector. These playbooks contain steps using which you can perform all supported actions. You can see bundled playbooks in the Automation > Playbooks section in FortiSOAR™ after importing the SAMBA connector.

Note: If you are planning to use any of the sample playbooks in your environment, ensure that you clone those playbooks and move them to a different collection since the sample playbook collection gets deleted during connector upgrade and delete.

Previous
Next