Note that there are some explanatory texts on larger screens.

plurals
  1. POSignalR getting 403 on AppHarbor after updating to v. 1.0.1 (Chrome)
    primarykey
    data
    text
    <p>I was using SignalR v. 1.0.0 RC2, and it worked fine. When I upgraded to v. 1.0.1 it stopped working. I am now getting a 403 (forbidden) when I am trying to invoke a method on the hub. I did not change any code - I only updated to the newer version of SignalR. It is important to note that I do not have any problems when I run it locally - only when I run it on AppHarbor, and only in the Chrome browser. It works in IE 10 and Firefox 20.</p> <p>I know that some work has been done in the newer version of SignalR for authorization. Now you can add an Authorize attribute on your hub, or your hub methods. I want to do that, but first I would like it to work without - like it did before.</p> <p>This is my hub:</p> <pre><code>using System.Threading.Tasks; using Microsoft.AspNet.SignalR; public class ReceptionHub : Hub { public Task Join(string group) { return Groups.Add(Context.ConnectionId, group); } } </code></pre> <p>And this is the client site script (I get the group from a data attribute in the markup):</p> <pre><code>$(function () { var receptionHub = $.connection.receptionHub; receptionHub.client.updateStatusBar = function (checkedIn, checkedOut, preRegistered) { $('#quantityCheckedInToday').html(checkedIn); $('#quantityCheckedOutToday').html(checkedOut); $('#quantityPreRegistered').html(preRegistered); }; $.connection.hub.start().done(function () { var group = $("#statusBar").data("group"); receptionHub.server.join(group); }); }); </code></pre> <p>One difference between my local setup and the setup on AppHarbor is that I run the AppHarbor site on HTTPS, but that was not a problem before. Also, there is a loadbalancer infront of the server on AppHarbor.</p> <p>The request that fails is a POST request to this URL:</p> <pre><code>/signalr/send?transport=serverSentEvents&amp;connectionToken=5hSSl7wSPrkD51cmPNw-JCrrdxMn2qOgEgmKt5gKrE4jigE4Sxha3gALHREcyDslqb7xjY9fP8rTMpslKuBJzBCIi-q86ZmHt66xhqi2eioAtvQCO03XlcR0Dq9-RW5G0 </code></pre> <p>Any help is much appreciated</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload