Weird problem here, newly configured gwia. Internally, if I telnet to the gwia and type "ehlo" then correctly get the expected output like:

220 mail.domain.com ready
ehlo
250-mail.domain.com
250-AUTH LOGIN
250-8BITMIME
250-DSN
250 STARTTLS

However, from outside, ehlo fails:
220 mail.domain.com ready
ehlo
500 Syntax error, command unrecognized
ehlo test.com
503 Bad sequence of commands
helo
500 Syntax error, command unrecognized
helo test.com
250 mail.domain.com Ok

So from outside, only "helo somedomain" succeeds.

I am pretty sure this is a hosts problem; in consoleone GWIA the A record is configured correctly and external DNS resolves to the gwia public IP
Internally, I had a hosts file entry that pointed to the internal IP of the mail server on the gwia machine, but even if I remark it (so that it resolved to the external IP) and restart the gwia, I have the same problem.

It's not access control, I removed gwac.db for testing, but same result.

I have another similarly configured GW and it works fine.

Thanks for any hints!