In our application, the backend is accessed via Zend_XmlRpc. In the backend, I'm using Zend_Http_Client together with Zend_Http_Client_Adapter_Curl to connect to another web service over HTTPS.
During unit tests, everything works as expected and the remote service is accessible. But when the frontend connects via Zend_XmlRpc to the backend and causes the backend to do the exact same thing like the unit tests do, I get the following error:
inet_pton(): Unrecognized address test.example.com#0 (url changed)
This is caused by Zend_Validate_Ip->isValid('test.example.com').
The only difference I can spot is the additional frontend-backend-connection which is also using Zend components for communicating. Everything else is the same.
Anybody any idea?
Looks like it might be a resolver issue in the server and zf isn't catching it beforehand. It's getting a hostname where it should be getting an IP address (obviously), and it can't convert a string to a binary IP address
It was an error in Zend_Validate that was fixed with release 1.9.
Related
Local and preproduction versions of my website have same configs and same source code. For some reason preproduction version unable to communicate with Facebook API. When I'm trying to login using Facebook I'm getting such strange error:
Google translates the error message like this:
"You can not load the URL: field is not a URL is included in this application areas. To download this URL, please add all domains and sub-domains for your application to the "application domains" field in the application settings."
I have tried to add my domain to the list, but it didn't help.
The truth is, I'm stuck and I would be grateful for any hint what to do with the error.
P.S. Also I have no idea why the error message is in Arabic - Server from Germany and has en_US.utf8 locale.
Update Settings Basic (domain name changed)
Finally I found the issue. I've used cascade of reverse proxies (nginx), which modified $_SERVER['SERVER_PORT']. The modification leaded to inconsistency between generated redirect_uri and the value was specified in app settings in Facebook developer console.
I've been developing a Symfony app (learning Symfony with the goal of replacing an existing "old school" PHP script with it) and am having an issue with putting it "behind" our Shibboleth authentication.
Why do that? For this app I need $_SERVER['REMOTE_USER']. The app doesn't have local accounts, the user doesn't log into the app, but, like many resources, we protect them with some form of authentication.
I have two sites - virtual hosts running on the same physical server. (CentOS 7). The first site has the following in its .htaccess file:
authtype shibboleth
ShibRequestSetting requireSession 1
require valid-user
I have a "phpinfo.php" file in there, too, and can run that script and, after the Shibboleth authentication step, get the output which includes the correct value of REMOTE_USER.
The other virtual host is set up as a Symfony 3.1 app. I've added those three lines to the top of its ".htaccess" file - but after going through the Shibboleth authentication step, the browser gets into a loop and goes no farther. (In Chrome, the 'favicon' is replaced with a looping arrow, and it never stops turning.)
If I hit and then view the source of this still-empty page, I see the following error message:
Error Message: Error decoding authentication request message
I'm not sure how to start to resolve this issue, and was hoping that someone has seen this and knows how to help.
Thanks.
Best,
Stephen
If I understand well, you are trying to make the Service Provider part in Symfony and you already have an IDP working with Shibboleth.
In my case I had also a similar problem and it was because after the Assertion the apache SP was returning to the root URL. I learnt after reading a lot of documentation that if this is not set correctly you can add an attribute in the shibbolet2.xml configuration called homeURL:
<ApplicationDefaults entityID="https://sso/saml2/idp/metadata.php"
REMOTE_USER="mail"
homeURL="https://symfonyApp/redirect/after/login">
Try it out and restart the shib daemon: /etc/init.d/shibd restart
It may be another as well. But it sounds to me that there is some misconfiguration in your SP side.
It's pleasure to be here; hoping a good support from all.
I am developing this application using personal FrameWork (CITS: construesol.com/our-solutions/cits-framework.html)
Facing the following issue, and not sure if this is due to some server or issue in my framework.
This Works: wrosc.commbuss.com/index.php
This gives Page not found error:
wrosc.commbuss.com/index.php?login__ga=GA1.2.1438238513.1446927241&
login_ck_login_id_20=1&
login_ck_login_language_20=en_us&
login_default_horde_view=auto&
login_PHPSESSID=evnvh60rcd8j37b64ajbb02vi7&
login_feacc482788c1ab9a7c03bcd5b19c90e=CookieEnabledClient
These are the additional paramaters passed from my machine; may be due to some tools I am using with my browser; like FireBug
&login__ga=GA1.2.1438238513.1446927241&
login_ck_login_id_20=1&
login_ck_login_language_20=en_us&
login_default_horde_view=auto&
login_PHPSESSID=evnvh60rcd8j37b64ajbb02vi7&
login_feacc482788c1ab9a7c03bcd5b19c90e=CookieEnabledClient
I am running a loop for $_REQUEST to check if some parameters are passed to redirect user to proper module (Parameters received: This is the feature of the framework).
The problem is only with this machine (and all developer) and not on "Non-Developer" machines; As we think this is due to some tools we are using with browser (e.g. FireBug)
NOTE: **** "login_" in front of each parameter is performed by the framework
Resolved the bug: Issue was with Framework, handled using urlencode
***But still those parameters are passed.
I'm trying to use the php shopify api library created by
cmcdonaldca at https://github.com/cmcdonaldca/ohShopify.php and
I am getting this error:
The redirect_uri and application url must have matching hosts
This occurs after I type in the shop name of [myshopname].myshopify.com and
the error appears on a page with this url:
https://[myshopname].myshopify.com/admin/oauth/authorize?client_id=[myclientid]&scope=Customer&redirect_uri=http%3A%2F%2Flocalhost%2Ftest%2FshopifyAPITest2.php
I'm doing this development locally so my host is localhost, is that really
the issue? The first time I tried entering a shop name I got to the
shopify page asking me to login, but then when I tried it again later it is
giving me the error. Is there some session variable that was set initially
that is causing the error? It doesn't look like it based on the error, but
that's what the behavior suggests.
Please help me understand how to address this issue. If it really means
the api script needs to be hosted at myshopify.com (the host for
[myshopname].myshopify.com) how would I put a php script there?
Thank you
The error you're receiving is telling you that the domain of the application URL you entered for the app in the Partners dashboard differs from the one you're providing with your OAuth request.
Make sure it's listed as localhost and the error should go away.
Also, make sure you have set your API key and shared secret correctly in config/application.rb
I am getting intermittent "Unauthorized" error messages, when attempting to call an external web service. When I get this message, if I continually reload the page, it will eventually work.
Has anyone ever encountered a similar problem? Do you think it is a server issue? I am kinda wondering if it is a bad load balanced server or something.
The web service is being called via HTTPS.
Thank you for your question.
The "401 Unauthorized" error can be caused by the following issues:
Wrong development / production key or wrong development / production password. Please double check that the credentials you are providing are the ones given by Purolator when you applied for the keys. If five consecutive requests are sent to the server with a wrong password, the key automatically gets locked. You will either have to apply for another key or contact Purolator to unlock your key. (Note there are special characters that are part of the passwords like ":", "$" etc, you might need to use single cotes or the escape character)
Pointing to the wrong server.
If you are using the example codes on the Resource Center in your development stage, these are pointing to the production server. In order to fix this, you just need to add "DEV" (development) as a prefix for the location URL:
For example in PHP: 'location' => "https://devwebservices.purolator.com/PWS/V1/ShippingDocuments/ShippingDocumentsService.asmx" (in this case for Shipping Documents Service)
To point to the Production server use: 'location' => "https://webservices.purolator.com/PWS/V1/ShippingDocuments/ShippingDocumentsService.asmx" (in this case for Shipping Documents Service)
Feel free to post any Purolator specific questions (web services) on our Technical Support Forum for a prompt response: http://purolatorwebservices.com
Thank you,
Purolator E-Ship Web Services Team
webservices#purolator.com