Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
cancel
Showing results for 
Search instead for 
Did you mean: 
vinay_lohakare5
Contributor

Requirement:

Load data to SFTP folder Using Authorization Type as Public Key in SAP Data Service

Description:

The blog will provide information about the use of file location object to upload file in SFTP server using Authorization Type as Public Key

We already have a blog that give you a good idea of how to use the File location object to access files in SFTP and FTP after Document Version: 4.2 Support Package 6 (14.2.6.0). The blog talks of the file config using the authorization type as password.

Export File to SFTP/FTP

I will be focusing only on the SFTP file upload using authorization type as Public Key:

vinay_lohakare5_0-1706703194318.png

Follow the steps to create the file location for SFTP as mentioned in the above blog.

Select the authorization Type as “Public Key” and you would get the below options:

vinay_lohakare5_1-1706703209636.png

You will be provided by the Username and RSA Private key by the SFTP team. With the provided RSA private Key, you won’t be able to create the connection and would get the below error message:

vinay_lohakare5_2-1706703244667.png

To resolve the error, use a software that would be able to generate the Public and Private key using the provided RSA Private key. We have used “PuTTY Key Generator” (You can use any other available software).

Open the PuTTY Key Generator and Go to File and select “Load Private Key”.

vinay_lohakare5_3-1706703297681.png

Once loaded you can select “Save public Key” followed by “Save private key”. The Public key should be saved by file extension “.pub” and the Private key with file extension “.pem”.

Note – You can also paste the generated public/private key in a note pad and save it with the extension as mentioned above.

File Location Configuration:

vinay_lohakare5_4-1706703355205.png

  • Name: Name of the file location
  • Protocol: Type of protocol (SFTP in our example)
  • Port: you can leave it default. Usually for SFTP it is 22 and for FTP it is 21
  • HostKey fingerprint: It is required for SFTP not for FTP. But don't worry system will propose this key once user and other provided details are passed.
  • SSH Authorization Private Key file path: The file path where the Putty Generated Private key is saved.
  • SSH Authorization Private Key Passphrase: Generated
  • SSH Authorization Public Key file path: The file path where the Putty Generated Public key is saved.
  • Remote Directory: SFTA Path where the generated file is to be pushed.
  • Local directory: Required only if you are copying it to local system folder.
  • Connection retry count and interval can leave as it is.

Once the file location is configured go to the file in data flow chose the file location from drop down.

Provide the file name and you are good to go 🙂.

 

 

 

Labels in this area