【问题标题】:RPXLib.dll throwing the exception The remote server returned an error: (500) Internal Server ErrorRPXLib.dll 抛出异常远程服务器返回错误:(500)内部服务器错误
【发布时间】:2011-01-03 14:01:12
【问题描述】:

我正在尝试将站点登录设施构建为单点登录。一些我如何来到 Janrain 站点,在那里我找到了 API。我也在我的 asp.net MVC 应用程序中尝试这个。这样我就按照here 给出的步骤进行操作 我遵循了给出的确切步骤,所以我认为没有必要在这里给出代码。但在我的行动中:

public bool signin(string token)
        {
           // string token = token_url;
            RPXLib.RPXService service = new RPXLib.RPXService(new RPXLib.RPXApiSettings("https://singlesignontest.rpxnow.com/api/v2/auth_info", "56fd9a76a5da4dffb9a437fe09564544b209c622"));
            try
            {
                RPXLib.Data.RPXAuthenticationDetails userDetails = service.GetUserData(token); //*Exception here* 
                return true;
            }
            catch (RPXLib.Exceptions.RPXAuthenticationErrorException ex)
            {
            } return false;
        }

我在指定的代码行处遇到异常。我正在正确地获得令牌价值。但无法继续前进。例外是:

The remote server returned an error: (500) Internal Server Error.

Stack Trace:

[WebException: The remote server returned an error: (500) Internal Server Error.]
   System.Net.HttpWebRequest.GetResponse() +5313085
   RPXLib.RPXApiWrapper.Call(String methodName, IDictionary`2 queryData) in D:\Development\Projects (3rd Party)\RpxLib\src\RPXLib\RPXApiWrapper.cs:50
   RPXLib.RPXService.GetUserData(String authenticationDetailsIdentifier) in D:\Development\Projects (3rd Party)\RpxLib\src\RPXLib\RPXService.cs:156
   SingleSignOn.Controllers.HomeController.signin(String token) in D:\ParallelMinds\Study Material\MVC\SingleSignOn\SingleSignOn\Controllers\HomeController.cs:37
   lambda_method(ExecutionScope , ControllerBase , Object[] ) +140
   System.Web.Mvc.ActionMethodDispatcher.Execute(ControllerBase controller, Object[] parameters) +17
   System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters) +178
   System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +24
   System.Web.Mvc.<>c__DisplayClassd.<InvokeActionMethodWithFilters>b__a() +52
   System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation) +254
   System.Web.Mvc.<>c__DisplayClassf.<InvokeActionMethodWithFilters>b__c() +19
   System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodWithFilters(ControllerContext controllerContext, IList`1 filters, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +192
   System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName) +314
   System.Web.Mvc.Controller.ExecuteCore() +105
   System.Web.Mvc.ControllerBase.Execute(RequestContext requestContext) +39
   System.Web.Mvc.ControllerBase.System.Web.Mvc.IController.Execute(RequestContext requestContext) +7
   System.Web.Mvc.<>c__DisplayClass8.<BeginProcessRequest>b__4() +34
   System.Web.Mvc.Async.<>c__DisplayClass1.<MakeVoidDelegate>b__0() +21
   System.Web.Mvc.Async.<>c__DisplayClass8`1.<BeginSynchronous>b__7(IAsyncResult _) +12
   System.Web.Mvc.Async.WrappedAsyncResult`1.End() +59
   System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) +44
   System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) +7
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +8674318
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +155


Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053 

并要求从路径打开 RPXLibWraper.cs。

 D:\Development\Projects (3rd Party)\RpxLib\src\RPXLib\RPXApiWrapper.cs

我要做什么?

【问题讨论】:

  • 请在此处进行任何更新.....我是这个概念的新手。
  • 那里有任何活着的预兆????????????????????????......为此感到羞耻。

标签: asp.net-mvc-2 rpxnow


【解决方案1】:

我现在确实遇到了同样的问题并解决了。我正在使用他们的助手 c# 类,路径 /api/v2/ 在那里被硬编码。因此,您也不能在 https://rpxnow.come/api/v2/ 字符串中拥有该路径,这是新 Rpx() 调用的参数。因此,只需将不带 /api/v2/ 的 url 发送到新的 Rpx() 调用。帮我解决了。

祝你好运!

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2015-03-27
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多