metaregistrar / php-epp-client

Object-oriented PHP EPP Client
https://www.metaregistrar.com/docs/
MIT License
214 stars 156 forks source link

How to pass a PEM file? - (Error: connection refused) #142

Closed damiaanr closed 6 years ago

damiaanr commented 6 years ago

The system works perfect for me locally. However, on a (shared) online server I get the following error with the exact same settings and files:

_Warning: stream_socketclient(): unable to connect to ssl://testdrs.domain-registry.nl:700 (Connection refused)

It seems like this problem is related to a certificate issue. Unfortunately I can't seem the find the proper answer, even after hours of googling. How to solve this problem on a shared server?

Kind regards, Damiaan

madaritech commented 6 years ago

Same issue for me with the test server: works locally, but on shared server i got:

_Warning: stream_socketclient(): unable to connect to ssl://eppltest1.metaregistrar.com:7000 (Connection refused)

damiaanr commented 6 years ago

Hmm, interesting. Does it work for you in production environment?

madaritech commented 6 years ago

Never tested in production. Currently i'm working exclusively on test. Do you have similar issues in test?

metaregistrar commented 6 years ago

Most of the times this is a whitelisting problem - is your IP address whitelisted?

metaregistrar commented 6 years ago

testdrs.domain-registry.nl does not need an additional certificate, we use it a lot.

metaregistrar commented 6 years ago

The parameters to specify a certificate file and certificate password have been added to the README.md file

metaregistrar commented 6 years ago

But they are not needed for the connection to SIDN ;-)

damiaanr commented 6 years ago

That's interesting since SIDN states IP addresses need not be whitelisted for their 'Registrar Test Environment' (testdrs.domain-registry.nl). Could it be, although I find it unlikely, that the IP address of my shared server has been blacklisted from the test environment (since on local, everything works fine)? Is there any other advice on how to proceed?

metaregistrar commented 6 years ago

If it works from one IP address and not from another, it MUST be a whitelisting issue. Your question is then best directed to SIDN

madaritech commented 6 years ago

Yes my ip address is whitelisted. Also tried disabling the whitelist option, but nothing change, locally works while on server got connection refused. Any hints?

metaregistrar commented 6 years ago

Outgoing firewall rules. They get us every time. Make sure port 700 is open.

perfectsenseab commented 6 years ago

Does you machine have have an IPv6 address in addition top IPv4? Maybe you're trying to connect from an incorrect source IP. If so, try whitelisting the IPv6 address also or disable it.

2018-04-17 9:18 GMT+02:00 Ewout de Graaf notifications@github.com:

Outgoing firewall rules. They get us every time. Make sure port 700 is open.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/metaregistrar/php-epp-client/issues/142#issuecomment-381874721, or mute the thread https://github.com/notifications/unsubscribe-auth/AKAypK-jMVCalbYg2ciC_DrFKbw8km5Iks5tpZdSgaJpZM4TVpkI .

-- Med vänlig hälsning, Jimmy Persson Perfect Sense AB / Webb.se | Vasagatan 58, 41137 Göteborg E-post: info@perfectsense.se Webb: https://www.webb.se

Följ oss gärna på Twitter https://twitter.com/webb_Se, Facebook https://www.facebook.com/webbdotse och Google+ https://plus.google.com/+WebbSe_domain/

madaritech commented 6 years ago

Ok, port was closed. Thank you very much for the hint. Now is open but i get another error message: "ERROR: Unexpected closed connection by remote host..." Again, locally it works with no problem. IP is white listed and I also checked ipv6: machine don't have it. So guys, do you have other hints? What should i check? Thanks a lot.

madaritech commented 6 years ago

Ok, I have an update: now it works. I didn't do nothing. Maybe system just need time. However now is working, thank you so much for support.