If you use docker there is a chance you get error because of OpenSSL default security level.
You need lower seclevel in /etc/ssl/openssl.cnf
from DEFAULT@SECLEVEL=2
to DEFAULT@SECLEVEL=1
Or just add into Dockerfile
RUN sed -i "s|DEFAULT@SECLEVEL=2|DEFAULT@SECLEVEL=1|g" /etc/ssl/openssl.cnf
Source: https://github.com/dotnet/runtime/issues/30667#issuecomment-566482876
After that change I can run SoapClient without any additional options
You can verify it by run on container
curl -A 'cURL User Agent' -4 https://ewus.nfz.gov.pl/ws-broker-server-ewus/services/Auth?wsdl