Hi
I used FTPAPI many times without problems. Now I am facing problems to do login to the ftp server. If I try from command line of my i, the login is successful, if I do login using Ftpapi, using the same user and password, I receive "login incorrect". I think that the problem is thet the password contains two special characters "@" and "#". As I can't change the password given how can I solve this? Using google I saw that my problem is not unusual and some people suggested to use "\" before this special characters.Any other suggestion.
Thanks in advance
Mario
Problem to do login with password with special characters
-
Scott Klement
- Site Admin
- Posts: 990
- Joined: Sun Jul 04, 2021 5:12 am
Re: Problem to do login with password with special characters
How do you have CCSID translation configured for FTPAPI?
How are you providing the password with the special symbols? Have you made sure it is giving the correct values to FTPAPI? Have you checked how FTPAPI is translating them?
How are you providing the password with the special symbols? Have you made sure it is giving the correct values to FTPAPI? Have you checked how FTPAPI is translating them?
-
peder udesen
- Posts: 36
- Joined: Thu Jul 29, 2021 8:00 am
Re: Problem to do login with password with special characters
Hi Mario
Have you solved your problem?
Then it would be interesting to know how and what you did.
Many years ago I was fighting a program that had problems with the character "@" and CCSID.
"@" was in mailadresses retrieved from files. In the end I gave up and translated it to the
value that was converted to the right value.
I made a comment in the program about this and the reason.
It is here ( in english ):
Normally we run with CCSID 277, but on some occasions CCSID 37 (USA) is used
This happens for example when backing up on XX-IBM i.
It causes some trouble with "@", where for CCSID 37 it has the value x'7C', while for
CCSID 277 it has the value x'80'.
For some reason, the SNDDST command expects "@" to have the value x'80',
regardless of which CCSID the job runs under, so we translate it here.
The only thing we are not allowed to do is have the danish character "Ø" in the email address for CCSID 277,
but how often does that happen?
wpMail = %xlate( x'7C' : x'80' : wpMail);
I hope this will give you a solution to the problem.
Regards
Peder
Have you solved your problem?
Then it would be interesting to know how and what you did.
Many years ago I was fighting a program that had problems with the character "@" and CCSID.
"@" was in mailadresses retrieved from files. In the end I gave up and translated it to the
value that was converted to the right value.
I made a comment in the program about this and the reason.
It is here ( in english ):
Normally we run with CCSID 277, but on some occasions CCSID 37 (USA) is used
This happens for example when backing up on XX-IBM i.
It causes some trouble with "@", where for CCSID 37 it has the value x'7C', while for
CCSID 277 it has the value x'80'.
For some reason, the SNDDST command expects "@" to have the value x'80',
regardless of which CCSID the job runs under, so we translate it here.
The only thing we are not allowed to do is have the danish character "Ø" in the email address for CCSID 277,
but how often does that happen?
wpMail = %xlate( x'7C' : x'80' : wpMail);
I hope this will give you a solution to the problem.
Regards
Peder