OpenX API connection - asp.net

While trying to connect to OpenX with the following code: (asp.net, c#)
IOpenXProxy proxy = (IOpenXProxy)XmlRpcProxyGen.Create(typeof(IOpenXProxy));
proxy.Url = "http://testserver.com/OpenX/www/api/v2/xmlrpc/";
proxy.Logon("username", "password");
I am getting an error message:
Response from server does not contain valid XML. "'--' is an unexpected token. The expected token is '>'. Line 31, position 3."
Using Fiddler it's possible to find out that the response I am getting is http://testserver.com/www/admin/index.php i.e. html login page. Because of that I am getting this error message.
The question is what is wrong? Server settings?
Thank you

The link was wrong: should be "http://testserver.com/www/api/v2/xmlrpc/".

See OpenX.NET to use OpenX from a .Net application. I recommend using ISession instead of IOpenXProxy

Related

"The provided value for the input parameter 'redirect_uri' is not valid" Using firebase

Firebase tells me to do this:
So I did
But I'm still getting this error "The provided value for the input parameter 'redirect_uri' is not valid"
I feel like I've followed instructions exactly but it's still not working. I have no idea how to debug this further. Any suggestions?
Here is my frontend code where I call signIn
let provider = new firebase.auth.OAuthProvider("microsoft.com");
provider.addScope("Calendars.Read");
firebase.auth().signInWithPopup(provider).then(handleResponse);
Edit
I changed the url to my custom domain and it seemed to be working but now I'm getting Error getting verification code from microsoft.com response: proof key for code exchange is required for cross-origin
For some reason Firebase decided to change the url where it handled auth. Instead of using the .firebaseapp.com/__/auth/handler url, it is using my actual custom domain. Though I don't really understand why this would happen...?
The Error getting verification code from microsoft.com response: proof key for code exchange is required for cross-origin was happening because I had configured an SPA on Azure instead of a Web platform.

"No route found" error with Asana Connect

As per this, I'm trying to use the code received from the authorization endpoint to exchange for a token, using the Authorization Code Grant flow. I first issue this call:
https://app.asana.com/-/oauth_authorize?response_type=code&client_id=123468022031234&redirect_uri=urn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob&state=foo
(I admit I don't know how the 'state' param should be used - the documentation doesn't clarify this, and it's required; also, my app is not web-based so the value for the redirect URL is auto-generated on the Developer App Management page for my app)
That gives me this code (slightly obfuscated): 0/12341234fd6ccf6d168420f7f8600c93
Which I then use for this call:
https://app.asana.com/-/oauth_token?grant_type=authorization_code&client_id=123468022031234&client_secret=1234123442d5048f64ac39ca857ec57a&redirect_uri=urn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob&code=0%2F12341234fd6ccf6d168420f7f8600c93
Which unfortunately returns "No route found" instead of the token I need. What am I doing wrong?
It has to be a POST. I was using a GET call.

Web Api 2 Self Host with identity individual account

I have been trying to create a web api 2 that is secure with individual account.
So I can easily create WebApi2 with individual account, see link below
http://www.asp.net/vnext/overview/authentication/individual-accounts-in-aspnet-web-api
And Self hosting is easy to do.
http://www.asp.net/web-api/overview/hosting-aspnet-web-api/use-owin-to-self-host-web-api
But I cannot figure out how to combine the solutions.
Far as I got was adding a console app to a webapi2. Which seems to run. But whenever I try and get the access token it returns
An unhandled exception of type 'System.Net.WebException' occurred in System.dll
Additional information: The remote server returned an error: (500) Internal Server Error.
If anyone knows of a solution that would be great. Thanks
This post is way old, but to anyone else who is having this issue and finds this question, I was able to get past the 500 Error by adding app.UseWebApi(config); after setting up config, as mentioned in this post:
http://odetocode.com/blogs/scott/archive/2013/07/24/self-hosting-webapi-with-katana.aspx
HOWEVER, I'm now getting a 401, unauthorized request for all of my requests, even though I have a valid token and I'm sending it the same way I did that worked in the non-self-hosted WebApi2 app. but I'm one step closer anyways.

IBM Worklight adapter using security tests

I'm using Workilight version 6.0 and I'm trying to use a security test with Workilght's adapter.
First of all, I developed a login page and home page where I'll display some informations after the user will be authenticated.
The authentication seems to be OK because I'm getting the user information and session Id which I'll sent in the cookie of the next HTTP adapter using the security test.
The problem is that I'm getting NullPointerException from the specified adapter but when I execute the request with RestClient, I get the response so the WS is OK.
Any body have an idea about how to that ?
PS: my code was working on worklight V5.0 but not with V6.0
I resolved this issue by deleting non useful Security Test like "MobileSecurityTest".
So before testing your adapter make sure that your declaration in the "authenticationConfig.xml" file is well done.
For more information about that, you can visit this URL :
http://public.dhe.ibm.com/software/mobile-solutions/worklight/docs/v600/08_03_Adapter_based_authentication.pdf
In addition, you have to figure out the root response in the adapter response to see first how looks your received data, otherwise you may be will receive a "NullPointerException" as response if you attempt to get for example "response.result" and the attribut "result" doesn't exist.
Hope that help you for future issues like I got.

SOAP-ERROR: Parsing WSDl

In my ASP.NET website I am trying to comsume a webserice and I and getting the following error:
SOAP-ERROR: Parsing WSDL: Couldn't load from 'https://usaepay.com/soap/gate/3213EA2A/usaepay.wsdl' : failed to load external entity "https://usaepay.com/soap/gate/3213EA2A/usaepay.wsdl"
Any idea on how to resolve it.
Thanks,
Pinaz.
The certificate for the host is for www.usapay.com. If you change your soap call to point at https://www.usaepay.com/soap/gate/3213EA2A/usaepay.wsdl your call should work.
Is it because there is an HTTPS error on the WSDL?

Resources