1

I'm having trouble with (Gmail) IMAP Access via OpenSSL (1.1.1g)

I connect to the server using the following (see here):

openssl s_client -crlf -connect imap.gmail.com:993

Login works fine with the following command:

tag01 login s***@gmail.com v***

For some reason I can not use any other commands (e.g. CAPABILITY or LIST "" "*") I always get an the error message:

tag02 LIST "" "*"
tag02 BAD Could not parse command

Any ideas?

1

In the end the answer was fairly simple, I had to remove the -crlf parameter, so the command to start openssl hast to be in my case:

openssl s_client -connect imap.gmail.com:993

I discovered that rather by accident, copying a command I used on a different server. Feel free to write a comment if you have other experiences.

Since I don't have enough time at the moment to dive further into this topic, I'll gladly accept a better answer if you know what exactly is going on in the background (especially if you know a way to figure out the right flags without using trail and error).

Note: A false -crlf flag used servers that are configured more strictly then google's IMAP doesn't even let you use the login command anymore (e.g. Strato returns: . BAD [CLIENTBUG] Too many parameters)

Note2: Don't forget to turn on IMAP and activate access for less secure clients otherwise you won't be able to log in.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.