Secure FTP using ABAP
Hello,
Can we do a secure FTP using ABAP code ??
Thanks
John
Hi John,
Sorry, I think the SAP function modules FTP_CONNECT, FTP_COMMAND und FTP_DISCONNECT are implemented according to RFC859 which is far behind secure connections. As SAP ftp goes throug SAP RFC destinations, this may be the spot where something has to be done to enable a secure connection.
Regards,
Clemens
Similar Messages
-
How to get the owner name for the file in ftp using abap ?
Hi folks ,
How to get the owner name for the file in ftp using abap ? please help me very ugernt . I tried with all standard FTP commands
but doest work out me . Helping in this regard highly appreciated ...
Thanks and regards,
Swarupa VanarchiHi
dont you have used the os user while calling the FTP_CONNECT FM?
Hope you are not talking about the user executing the FTP program.
Else If you are talking about the FTP file creator then its not related to abap as you can handle it by maintaining the user in file name itself.
May be i am going too far with if and elses here as your question possesses no clarity.
Plz elaborate your requirement before anybody can help.
Regards
sateesh -
Secure FTP using FTPS (SSL/TLS) - need help!
I am trying to use an FTP Sender Channel using Secure FTP. I am currently getting a "java.net.ConnectException: Connection timed out: connect" error.
I am on XI 3.0 with SP13.
Settings are FTPS (FTP Using SSL/TLS for Control and Data)
Command Order Auth TLS, USER, PASS, PBSZ, PROT.
I am able to connect from my pc using WSFTP Pro which looks to be using the same command order. I made sure WSFTP Pro was set for passive connections as XI only supports this until SP15.
I have asked our Basis support to make sure the proper ports are open that are used for the connection and file transfer. They have deployed the Java Cryptographic Toolkit on XID, and changed the startup mode for SSL runtime from 'manual' to 'always'. The site I will connect to uses a certificate from Equifax which was added to the TrustedCAs keystore view. After still not being able to get a file, I also added the certificate of the site, which I was able to export from WSFTP Pro and import onto XI with STRUST.
I have increased the J2EE trace for com.sap.aii.adapter.file to Debug, but I haven't been able to get much out of the log. I see entries, such as some SSL activity and the timeout, but nothing that points me to an answer. Of course, I really don't know what to look for.
I have tried to connect to the remote server by name or ip with the same connection timeout.
I currently don't have it set to use X.509 certificate for Client Auth, but I did try a few of those options with no luck.
Any pointers would be appreciated.
Thanks,
Eric PetersonEric,
Did you ever solve the problem ? I am having the same issue.
Cheers
Jon -
How to use secure FTP using FTP adapter in PI
Hi,
PI does not give SFTP adapter, for using the SFTP adapter we need some security certificates + we need to purchase the
SFTP adapter.
How to achive SFTP functionality using FTP adapter? We need to do some script coding.
Pl throw some light on this.
Thanks,
KrishnaHI Krishna,
Ref: http://weblogs.sdn.sap.com/cs/blank/view/wlg/22415
http://weblogs.sdn.sap.com/cs/blank/view/wlg/22776
http://aedaptive.com/index.php/solutions/pgp-for-sap-netweaver
Thanks, -
Unzip files from FTP using ABAP
Hi All,
I have the a requirement to unzip certain files from ftp and transfer the extracted files to another directory in ftp.
Searched (Re: Unzip file;) in SDN but didnt find the perfect solution
Appreciate the help.
Regards
SivaYou can use IndexOf function
see this example
http://visakhm.blogspot.in/2012/05/package-to-implement-daily-processing.html
Please Mark This As Answer if it solved your issue
Please Vote This As Helpful if it helps to solve your issue
Visakh
My Wiki User Page
My MSDN Page
My Personal Blog
My Facebook Page -
Hi Gurus,
We are trying to read a file from a server (e.g) XYZ.123.com and other details which are provided to us are user name (e.g): Abc123 and Directory (e.g): /123/123/123/123l.
My question is: Do we need a RFC connection to the server if yes then what type of RFC connection? If RFC connection is not required then what we have to do to establish the connection.
Thanks,
Abhishek.Hi Abhshk, there may be a more modern way but something like this has worked in the past
*-- FTP_CONNECT requires an encrypted password to work
call 'AB_RFC_X_SCRAMBLE_STRING'
id 'SOURCE' field mc_password
id 'KEY' field mi_key
id 'SCR' field 'X' id 'DESTINATION' field mc_password
id 'DSTLEN' field mi_pwd_len.
call function 'FTP_CONNECT'
exporting
*-- Your SAP-UNIX FTP user name (case sensitive)
user = 'unixuser'
password = 'unixpassword'
*-- Your SAP-UNIX server host name (case sensitive)
host = 'saphost'
rfc_destination = 'sapsystemrfc'
importing
handle = mi_handle
exceptions
not_connected = 1
others = 2.
check sy-subrc = 0.
call function 'FTP_COMMAND'
exporting
handle = mi_handle
command = 'dir'
tables
data = mtab_data
exceptions
tcpip_error = 1
command_error = 2
data_error = 3
others = 4.
Kevin -
Recommend a good secure FTP client
I am currently using Fetch 4.0.3 and it works well, but it will not allow me a secure connection. As a result, my password is NOT protected, and my website has been compromised. I have been advised to change my password, which I have done, but still, I can't log on with encryption. Not sure why, but "enable encryption" is grayed out and not available.
Is there a better FTP client that I could switch to. One that will assure a secure connection? What does everyone recommend?Hi Rob--
I'll second the suggestion of Transmit or Cyberduck.
As for Fetch, there's secure then there's secure. Fetch 4.0.3 only supports secure passwords if your server supports the right kind of authentication (Kerberos). Perhaps what the people who were advising you was to use SFTP, which is a kind of secure FTP using SSH, which is very strong if you have a good password.
I'm pretty sure Cyberduck supports SFTP. I know Transmit does, and Fetch 5.0 and later supports SFTP, too.
charlie -
Can someone tell me what port Secure FTP uses? Is it different than the standard ftp port? Thanks in advance for any help given.
If you are talking FTP over SSL, 990/tcp is the default. The port is configurable depending on the server software you are using.
That is unless you are talking about SFTP which is over SSH 22/tcp (configurable). -
Can we do a Secure FTP for an XML file from ABAP when firewall is enabled?
Hi all,
I have a requirement to send an XML file to an External FTP Server which is out of our corporate network and our firewall is enabled.
I have to send an XML file with Purchase Order details. I completed that with the help of this blog https://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/2657. [original link is broken] [original link is broken] [original link is broken]
Now I need to FTP the XML file that is generated. How should I be doing this? Can some of help me with this?
I need to do a Secure FTP to the external non SAP server which is out of our corporate network and our firewall is enabled. Can some one tell me if SFTP is possible in ABAP.
This is not a web service. I am working on dropping an XML file in an external FTP serveru2026 I have searched the forums but still in a confusion if weather Secure FTP is possible in ABAP or not when our company firewall is enabledu2026
If some one encountered this situation earlier please help,,,..any help will be highly appreciated.
Regards,
Jessica SamThanks a lot for your valuable suggestions Richu2026
I agree with you Rich that web services would be a better option. But I need to send this file to an external third party and they dont have web services.
They are telling us that either we can send them an XML file or a CSV file in the format that they want. We decided to go with XML file format.
I am done with formatting the Purchase Order details in the format that they want. Now the challenge is that I need to send this FTP file to them and it should be a Secure FTP when our fire wall is enabled,
When you say
1) Run an ABAP program to generate the XML file and put it on the local PC
2) Log into the FTP site via some FTP client, could simply be windows as well.
3) Manually cut/paste the file from the PC to the FTP site.
For Step 1 running ABAP Program can I schedule a batch job?
For Step 2 and Step 3 can I automate it in any other way..if not in ABAP?
Can I advice my company to follow any alternate method in which they can automate this step 2 and step 3u2026if not in ABAP can it be possible in any other way as the third party does not have web services I now have no other alternative.
Please Helpu2026
Regards,
Jessica Sam -
SSIS and Secured FTP Commands to GET a Remote File using wildcards
So my biggest caveat here is dealing with wildcards! For the life of me I cannot find any good examples of SSIS and scripting that uses FTP wildcards to GET certain Files. In a nutshell, here's what I need to do...
Query a SQL Server Database which has a parsed File Name, the first 50 characters of the file name.
The Query "Result Set" is put into an Object Variable User::SQLServerFileList
I then utilize a "Foreach Loop Container" which reads the User::SQLServerFileList and puts it into Variable User::SQLServerFileNm...which is again the first 50 characters of the File Name
Within the "Foreach Loop Container", I then utilize an "Expression Task" which builds a variable User::RemoteFileLookup which is a concatenation of the User::RemoteFolderPath + User::SQLServerFileNm + the wildcard *(Variable
User::RemoteWildCard)
I then try and utilize a "FTP Task" to use that concatenated Variable to go and GET the Filename but every time I try, it does not like what I'm sending via the "FTP Task"
Error: 0x0 at TF Secure FTP Task, ExecuteTask Failed:: Illegal characters in path.
I realize I might have to do something like this via C#.
My biggest challenge is providing the GET Command via the Remote FTP Site with a parsed Filename and utilizing a wildcard.
mc7i1231_20140227_050114_27_05_02_09*.999
And the Filename that exists on the FTP Server is...
mc7i1231_20140227_050114_27_05_02_09_x12_a43419452ca844a9b8a00f61e655dca3.x12-20140303180032.999
Can any gurus out there PLEASE help me out???
Thanks in advance for your review and am hopeful for a reply.
PSULionRPHi PSULionRP,
According to the document
FTP Task, we can read that:
The FTP task supports the ? and * wildcard characters in paths. This lets the task access multiple files. However, you can use wildcard characters only in the part of the path that specifies the file name. For example, C:\MyDirectory\*.txt is a valid
path, but C:\*\MyText.txt is not.
So, when you use expression tobuild the variable RemoteFolderPath, make sure the evaluated value of the expression conforms to the above rule.
Regards,
Mike Yin
TechNet Community Support -
Using Secure FTP to extract a file
Dear all
we want to create a mapping to read data from a set of tables and after some transformation to export the data into a flat file over a secure FTP protocol to a remote location.
I am wondering :
a) if that is feasible and if yes, then
b) what are the parameters we have to use to achieve that.
many thanks in advanceA quick search at google reveals there are plenty of FTP libraries available for the various mainstream programming languages (Java, C, C++ etc).
However, FTP has a very basic command set. (MKDIR, GET, PUT, DEL etc).
So you are not going to be able to perform more advanced document management tasks (such as lock a document, check-in, check-out, modify metadata, modify security, search, sort etc) through standard FTP commands.
In terms of setting metadata through FTP, you could potentially store the various processing instructions required in some type of XML file (or equivalent) and upload this XML file to the repository. A custom event handler could be created that listens for DOCUMENT_CREATED events, and then attempts to process the XML files and perform the various instructions contained within by calling the appropriate in-process Content DB FDK API.
It's ugly, but possible.
cheers
Matt. -
Hi SDN,
I am new to XI can any one provide me clear documentation or link on "FTP to SAP using ABAP Proxy" on this senario. I mean the steps to create ABAP Proxy etc..
Thanks in Advance
Regards
BashaHi Shaik
Please go through the information provided in the blogs below which explains clearly the Scenario you want to try.
<a href="/people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy Proxies in XI</a>
<a href="/people/siva.maranani/blog/2005/04/03/abap-server-proxies Server Proxies</a>
<a href="/people/prateek.shah/blog/2005/06/14/file-to-r3-via-abap-proxy to R/3 via ABAP Proxy</a>
Please do let me know if you want any more help regarding the same.
Regards,
Abhy -
Is it possible to have a secure FTP connection using private key authentication?
Is it possible to have a secure FTP connection using private key authentication to connect to a folder on Business Catalyst?
Hi,
Not available at this stage as the only options can be found in the SFTP set-up article.
- http://helpx.adobe.com/business-catalyst/partner/connecting-site-using-ftp-client.html
Kind regards,
-Sidney -
How do you send by secure ftp from SAP R/3 4.6C on iseries
We have been using the SAP Standard program, RSFTP002, to ftp files to remote servers for many years. We have now had a requirement to send via secure ftp. We are using R/3 4.6C. Unfortunatley this is not a straight forward change and it seems we may need to install some client software to enable this.
I have searched for any SAP notes and in several user groups but have not been too sucessful.
Has anyone ever set this up before? What client software did you use?
Any pointers / advice on this would be much appreciated.
Many thanks,
StevenFurther to my initial post, I have now discovered that there are additional options on the ftp command on iseries, so I am hoping if I can perform this manaully, then a CL called from SAP would allow me to resolve this challenge.
I am trying to use the command below but this will use the port 990.
FTP RMTSYS(INTNETADR) INTNETADR('*.*.*.*') PORT(SECURE) SECCNN(*SSL)
The vendor is requesting that we use port 443 for secure ftp with SSL and even specifying this in the command as below still does not work. It seems to me there may be an issue at the receiving end. Port 443 is normally used for https so not sure whether specifying this port could cause issues. The resultant error is below.
FTP RMTSYS(INTNETADR) INTNETADR('*.*.*.*') PORT(443) SECCNN(SSL)
Connecting to remote host 62.39.53.181 using port 443.
No response from remote host; all connections closed.
Any other comments would be welcomed.
Many thanks,
Steven -
Unallowed RFC-XML Tag (SOAP_EINVALDOC) - Web Service using ABAP Proxy
Hi there
I am trying to consume a Web Service using ABAP Proxies. I have done the following in the system:
I configured the HTTP and HTTPS Proxy settings.
I created a package with package interfaces SAI_TOOLS and SAPPINT included under the Use Access tab.
I created the proxy classes by using the WSDL provided by the system I'm trying to interface with.
I created my HTTP destination RFC via SM59.
I configured a logical port for the proxy.
I developed the ABAP code for calling the proxy.
In the code the exception CX_AI_SYSTEM_FAULT gets raised with error message <b>"Unallowed RFC-XML Tag (SOAP_EINVALDOC)"</b> when I call the method for passing data to the destination system in the proxy class.
I had a look at SM21 and the following message was written in the log:
<b>"SOAP Runtime: SOAP Runtime exception: 111 occurred in method XP_READ_TAG of class CL_SOAP_XP at position 1
SOAP Runtime: Exception message: Unallowed RFC-XML Tag (SOAP_EINVALDOC)"</b>. I also looked at SAP Note 919886 which states that it can be dumps in the system, missing configuration or the path prefix of the RFC destination that is incorrect. I cannot find any ST22 entries. The trace file looks as follows:
SAP System ID: DGH
Client: 009
User: COLESKG
System time: 072910
System date: 20070531
SAP Release: 700
Host: hd307c
Operating system: AIX
DB System: ORACLE
Program: ZUK_IPA00003
Processing State: 0
Location: Client
Transport Binding: http://schemas.xmlsoap.org/soap/http
SOAP Application: urn:sap-com:soap:runtime:application:client
SOAP Runtime Protocol: http://www.sap.com/webas/630/soap
/runtime/protocol
SOAP Protocols: <initial>
Request Message: <initial>
Response Message: <initial>
Fault: <initial>
Registry: <initial>
SOAP Roles: <initial>
Trace Level: 3
Logging Level: 2
Monitoring Level: 0
Security Profile: <initial>
WS Security Protocol: <initial>
INFO 07:29:10: SOAP LP Registry CL_SRT_LP_MAINTENANCE->CREATE_CLIENT_APPL() Try to create client application for Proxyclass:
ZES_CO_PROCESS_EMPLOYEE_BATCH LP name: DEFAULT
INFO 07:29:10: SOAP LP Registry CL_SRT_LP_MAINTENANCE->CREATE_CLIENT_APPL() Client application created
INFO 07:29:10: SOAP LP Registry CL_SRT_LP_MAINTENANCE->CREATE_CLIENT_APPL() Try to initialize client application
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT->IF_SOAP_APPLICATION_CS~INIT() Try to initialize application
urn:sap-com:soap:runtime:application:client
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT->INTERNAL_CLIENT_INIT() Create new runtime CL_SOAP_RUNTIME_CLIENT
INFO 07:29:10: SOAP Runtime CL_SOAP_RUNTIME_CLIENT->REGISTER_APPLICATION() Try to register application
INFO 07:29:10: SOAP Runtime CL_SOAP_RUNTIME_CLIENT->REGISTER_APPLICATION() Application registered
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT->INTERNAL_CLIENT_INIT() Read type of transport binding from
configuration
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT->INTERNAL_CLIENT_INIT() Create new transport binding type
http://schemas.xmlsoap.org/soap/http
INFO 07:29:10: SOAP Transport Binding CL_SOAP_TRANSPORT_BINDING_ROOT->IF_SOAP_TRANSPORT_BINDING~INIT() Try to initialize
http://schemas.xmlsoap.org/soap/http
INFO 07:29:10: SOAP Transport Binding CL_SOAP_TRANSPORT_BINDING_ROOT->IF_SOAP_TRANSPORT_BINDING~INIT() http://schemas.xmlsoap
.org/soap/http initialized
INFO 07:29:10: SOAP Transport Binding CL_SOAP_TRANSPORT_BINDING_ROOT->IF_SOAP_TRANSPORT_BINDING~REQUEST() Try to create request message
INFO 07:29:10: SOAP Transport Binding CL_SOAP_TRANSPORT_BINDING_ROOT->IF_SOAP_TRANSPORT_BINDING~REQUEST() Request message created
INFO 07:29:10: SOAP Transport Binding CL_SOAP_TRANSPORT_BINDING_ROOT->IF_SOAP_TRANSPORT_BINDING~RESPONSE() Try to create response message
INFO 07:29:10: SOAP Transport Binding CL_SOAP_TRANSPORT_BINDING_ROOT->IF_SOAP_TRANSPORT_BINDING~RESPONSE() Response message
created
INFO 07:29:10: SOAP Runtime CL_SOAP_RUNTIME_CLIENT->INIT() Try to initialize
INFO 07:29:10: SOAP Runtime CL_SOAP_RUNTIME_CLIENT->INIT() Check transport binding
INFO 07:29:10: SOAP Runtime CL_SOAP_RUNTIME_CLIENT->INIT() Create runtime protocol
INFO 07:29:10: SOAP Runtime Protocol CL_SOAP_RUNTIME_PROTOCOL->IF_SOAP_PROTOCOL~INIT() Try to initialize SOAP Runtime-intrinsic
Protocol as SENDER with Priority 5
INFO 07:29:10: SOAP Runtime Protocol CL_SOAP_RUNTIME_PROTOCOL->INIT_MODULES() Try to create trace header/part
INFO 07:29:10: SOAP Runtime Protocol CL_SOAP_RUNTIME_PROTOCOL->INIT_MODULES() Trace header/part created
INFO 07:29:10: SOAP Runtime Protocol CL_SOAP_RUNTIME_PROTOCOL->INIT_MODULES() Try to create logging header/part
INFO 07:29:10: SOAP Runtime Protocol CL_SOAP_RUNTIME_PROTOCOL->INIT_MODULES() Logging header/part created
INFO 07:29:10: SOAP Runtime Protocol CL_SOAP_RUNTIME_PROTOCOL->IF_SOAP_PROTOCOL~INIT() Protocol initialized
INFO 07:29:10: SOAP Runtime CL_SOAP_RUNTIME_CLIENT->INIT()
Initialized
INFO 07:29:10: SOAP Protocol CL_SOAP_PROTOCOL_FACTORY->CREATE()
Try to create instance for http://www.sap.com/webas/630/soap
/runtime/session/protocol::http://www.sap.com/webas/630/soap
/runtime/session/protocol/srt640_impl
INFO 07:29:10: SOAP Protocol CL_SOAP_PROTOCOL_FACTORY->CREATE()
Instance of CL_SOAP_SESSION_PROTOCOL created for http://www.sap.com/webas/630/soap/runtime/session/protocol::http://www.sap.com/webas/630/soap/runtime/session/protocol/srt640_impl
INFO 07:29:10: SOAP SESSION Protocol CL_SOAP_SESSION_PROTOCOL->IF_SOAP_PROTOCOL~INIT() Try to initialize SOAP Session Protocol
as SENDER with Priority 5
INFO 07:29:10: SOAP SESSION Protocol CL_SOAP_SESSION_PROTOCOL->IF_SOAP_PROTOCOL~INIT() Protocol initialized
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT_GEN->CONFIGURE_FEATURES() Try to configure features
INFO 07:29:10: SOAP HTTP Binding CL_SOAP_HTTP_TPBND_ROOT->IF_SOAP_HTTP_TRANSPORT_BINDING~SET_CLIENT_BY_DESTINATION() Try to
create ICF Client for DESTINATION = ALSB
INFO 07:29:10: SOAP HTTP Binding CL_SOAP_HTTP_TPBND_ROOT->IF_SOAP_HTTP_TRANSPORT_BINDING~SET_CLIENT_BY_DESTINATION() ICF
Client created by DESTINATION
INFO 07:29:10: SOAP HTTP Binding CL_SOAP_HTTP_TPBND_ROOT->IF_SOAP_HTTP_TRANSPORT_BINDING~SET_DESTINATION_URL_PATH() Set
DESTINATION PATH = /SapHRSmartIntegrationWeb/processes/ProcessEmployeeBatch.jpd
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT_GEN->CONFIGURE_FEATURES() Features configured
INFO 07:29:10: SOAP Application CL_SOAP_APPLICATION_CLIENT->IF_SOAP_APPLICATION_CS~INIT() Application urn:sap-com:soap
:runtime:application:client initialized
INFO 07:29:10: SOAP LP Registry CL_SRT_LP_MAINTENANCE->CREATE_CLIENT_APPL() Client application initialized
Trace file opened at 20070531 073030 GMT SAP-REL 700,0,95
Error in module XMLParserGetNextElement:773
Id @(#) $Id: //bas/700_REL/src/krn/rfc/xrfcpars.c#2 $
Unallowed RFC-XML Tag
Error in module XMLConverterReadTag:3061
Id @(#) $Id: //bas/700_REL/src/krn/rfc/xrfccnvrt.c#5 $
Unallowed RFC-XML Tag(24)
Error in module ab_soap:4392
Id @(#) $Id: //bas/700_REL/src/krn/rfc/abxrfccal.c#2 $
failed with return code 1
It then must be something in the config. Has anyone got any idea why this message is encountered?
Kind Regards
Gustav Coleske
Message was edited by:
Gustav ColeskeHi,
I have the same problem as described.
Can you give me a little more information about the error you have solved in the proxy.
Thanks for help
John
Maybe you are looking for
-
Can I install iMovie 5 on an Intel mac?
Hello. I recently got a new Mac which came with iMovie 09 installed. If possible........I would like to also install iMovie 5 on the same machine (as I have lots of 3rd party effects with that version). So I'm wondering is this possible and how do I
-
How to read from input file and pass to script
How can I get rid of the hard coded PATH statement and feed script based upon text file input. Input is contained in a file.. 'C:\cntprocess\ called sistemfolder.txt that has 2 fields folder then shortname. example: C:\cntprocess\REW1___1~Rew1
-
i need help my iphone 5c has been on charge for 5 hours and still has not turned on past the charging symbol, what can i do? (baring in mind i got this phone 2 days ago brand new.)
-
hi all, firstly, i am noob at dreamweaver.I encountered a problem applying my template in html code in my pages.After i add new links in template page ,dreamweaver warns me to update pages created before.i do ok but when i opened pages i see they are
-
How do I transfer notes from iPhone3 to iPhone5?
how do I transfer notes from iPhone3 to iPhone5?