JayData supports basic authentication, so your JayData context can be initialized with the following parameters:
var yourContext = new YourContextType({
name: "oData",
oDataServiceHost: '/Northwind.svc',
user: "user",
password: "password" })
Of course you should pass these parameters from a login form and publish your backend service over https.