View Single Post
Old 09-29-2019, 11:23 AM   #3
feffe
Junior Member
feffe began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Sep 2019
Device: Kobo Aura One
Quote:
Originally Posted by Frenzie View Post
Note that there are at least two types of calibre server. If I'm not mistaken content server is OPDS and wireless connection is wireless connection, but the fact that you're talking about visiting from the browser suggests OPDS?
Thank you I think I figured it out now. I was using wireless connection under tools when I should have been using OPDS Catalog under the search tab. Specifying <node-hostname>:8081/opds works fine and downloading works. And I also see that this enables me to specify username and password so I can open the server externally, so that's nice. Kind of thought it wouldn't have that functionality .

Anyways, thank you for the clarification!

I'm now trying to get authentication to work, I've created a user under "Sharing over the internet > User accounts", enabled the option requiring authentication under "Sharing over the internet > Main" and entered the credentials under the opds catalog entry in koreader. This setup just returns error 400 (aka bad request).

This is how a request looked before entering the credentials:
Code:
09/29/19-16:33:47 INFO  request {
    ["url"] = "http://canti:8081/opds",
    ["method"] = "HEAD",
    ["headers"] = {
        ["Authorization"] = "Basic Og==",
        ["Host"] = "canti"
    },
    ["sink"] = function: 0x2ff49fb0
}
09/29/19-16:33:47 INFO  request {
    ["url"] = "http://canti:8081/opds",
    ["method"] = "GET",
    ["headers"] = {
        ["Authorization"] = "Basic Og==",
        ["Host"] = "canti"
    },
    ["sink"] = function: 0x2ff4d890
}
And this is how it looks now with credentials specified:
Code:
09/29/19-16:41:39 INFO  request {
    ["url"] = "http://canti:8081/opds",
    ["method"] = "HEAD",
    ["headers"] = {
        ["Authorization"] = "Basic <snip>",
        ["Host"] = "canti"
    },
    ["sink"] = function: 0x301b9270
}
09/29/19-16:41:39 INFO  request {
    ["url"] = "http://canti:8081/opds",
    ["method"] = "GET",
    ["headers"] = {
        ["Authorization"] = "Basic <snip>",
        ["Host"] = "canti"
    },
    ["sink"] = function: 0x301bcb40
}
Any ideas? Afaik 400 is only supposed to be used if any part of the request is bork but doesn't take into account content. So for example if "Authorization" had a bad value it would return 401. I don't see any difference here so in request layout so idk why it would return 400.

EDIT: and yes I've restarted the container multiple times after editing user and server settings.

Last edited by feffe; 09-29-2019 at 11:26 AM.
feffe is offline   Reply With Quote