phax / as2-lib

A generic Java AS2 library, servlet and server
107 stars 43 forks source link

Testing partnership data #35

Closed zharpaz-bmc-com closed 6 years ago

zharpaz-bmc-com commented 6 years ago

Hi, Implementing AS2, we want to validate a partnership's data before the first actual send. Can the library help with such a test? Thank you for your help, Ziv

phax commented 6 years ago

What part of the partnership data you want to test? Please give some example. Something like "does the alias exist in my keystore" or so?

zharpaz-bmc-com commented 6 years ago

I want to check that the remote URL is correct. If it needs user & password, that they are correct. If possible, that the certificate is correct.

phax commented 6 years ago

That's a tough thing to check, because there is no "ping" available. A server may (at least theoretically) block any other request than AS2 requests... How would you do that?

zharpaz-bmc-com commented 6 years ago

I thought to send a HEAD Query (as described in the as2 restart profile). At least servers that support restart will respond to it. What do you think?

phax commented 6 years ago

Well maybe. I can just tell you, that the as2-servlet currently doesn't support it (only POST). An as2-server (the standalone server project) not even supports AS2 over HTTP - it's a socket only connection...

zharpaz-bmc-com commented 6 years ago

I see. And as2-lib, does it supports HTTP/S? for sending?

phax commented 6 years ago

Yes, it does support http and https for sending of course. You can configure the certificate used, and you can even use a client certificate for sending. Also a proxy can be used

zharpaz-bmc-com commented 6 years ago

Thanks a lot for your answers Philip!