05-22-2017, 11:23 AM | #1546 |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
I can imagine.
I can reproduce this behaviour (enter username and password then <Sign In> then <Please Sign In> pop-up window disappears shortly and appears empty again) only if I somehow have enabled (through .htaccess) authentication and the username/password I enter are different from those in .htpasswd ("encrypted"). So try: - comment out the lines $config['cops_basic_authentication'] = ... in all config_local.php and config_local.userX.php files and try logging in again. What happens? or - make the username / password the same as in .htpasswd ("unencrypted") and try again. What happens? |
05-22-2017, 11:36 AM | #1547 | |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Quote:
I have no .htaccess or .htpasswd files in the cops111 folder, OR in the parent Web folder. There was .htaccess in /Web/cops101, not being tested at the moment. [Edit] Does ANYONE actually have this working?? Last edited by MontyJ; 05-22-2017 at 11:58 AM. Reason: Update |
|
Advert | |
|
05-22-2017, 12:08 PM | #1548 |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
Yeah me! But not on a QNAP.
If you enable authentication through .htaccess/.htpasswd does that work like you want it to? |
05-22-2017, 12:26 PM | #1549 | |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Quote:
Does this appear to be a specific Python issue? My current Python install is V2.7.12. I see there is a Python3 V3.5.2.0 available from the official QNAP install repository. Not sure of the downsides to installing the new one, but am willing to try if you think it may be specific to Python. Last edited by MontyJ; 05-22-2017 at 01:07 PM. Reason: Clarify |
|
05-22-2017, 01:11 PM | #1550 |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
python -V gives on my setup Python 2.7.9
What's your PHP version (php -v)? PHP 5.6.30-0+deb8u1 |
Advert | |
|
05-22-2017, 01:18 PM | #1551 |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
With working .htaccess put this file in your cops111 directory: (assuming/knowing) you have a working user monty.
config_local.monty.php Code:
<?php /* * Catalog's title */ $config['cops_title_default'] = "MONTY COPS"; In my setup if I login with user monty it works. |
05-22-2017, 01:32 PM | #1552 | |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Quote:
Code:
[/share/Web] # python -V Python 2.7.12 [/share/Web] # I will report back once it is installed and tested. I tried php -v, but nothing found. I see a lot of php5 files in the qts system, but php5 -v doesn't bring up anything either. Still loading the new python 2.7.13... Last edited by MontyJ; 05-22-2017 at 02:08 PM. Reason: update |
|
05-22-2017, 02:20 PM | #1553 |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Well, appears I have buggered the system somehow; now the old COPS doesn't even work after the new python update.
Back to square one....reset system, start clean. Thanks for the help! |
05-22-2017, 04:30 PM | #1554 |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
@mariosipad,
Do you know if the cops authentication process depends on 1 or more specific modules in Python? I have a list of the modules and can check to make sure the right modules are there. I have the qnap back up, in virgin state, except did load cops1.1.1 with a single calibre library for testing. It does work with the original .htaccess file left in the cops folder, but no .htpassword file. But, it does not work when I put in cops authentication...same problem as before. This default version of Python is 2.7.5. I have queried the qnap gurus about loading the new 2.7.13 but haven't done it yet. |
05-22-2017, 04:37 PM | #1555 |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
As far as I know cops does not depend on python. No need to Install other modules just for cops.
Cops depends on PHP. If checkconfig.php = ok in the first line, then it's ok. Can you find out which apache modules are enabled in the QNAP webserver? Last edited by mariosipad; 05-22-2017 at 04:44 PM. |
05-22-2017, 05:16 PM | #1556 | |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Quote:
However, per the hints, I checked php.ini for any mention of "intl" or "Intl" and no hits. In previous setups I had installed Entware because it had the Intl php5 module. but I noticed that line in the check config screen never says OK, just to check Intl installed and activated. But I am holding off Entware to keep the system as clean as possible while trying to get this to work. So I don't know if Intl ever got loaded in php.ini or not, even with Entware. Could that be part of this problem? I also attached a txt file of the loaded apache modules. Not sure how to tell if they are available to the "QNAP Webserver", but the list shows ALL apache modules, according to the qnap guides. [Edit] Forgot to mention; I setup COPS111 normally using the default port 80, no Virtual Host for it until we get this sorted out...until everyone throws up their hands in despair, that is Last edited by MontyJ; 05-22-2017 at 05:22 PM. Reason: Update |
|
05-22-2017, 06:03 PM | #1557 |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
1 - checkconfig.php looks OK
-> the missing intl is no problem. Probably only used with latin (French, Spanish, etc) languages. Just disregard any messages about intl. Not a part of the problem. 2 - the text file list (as you said) all the available modules not just the "active/loaded" ones. But if .htaccess authentication works(worked once) then there should be no problem. 3 - now put the line Code:
$config['cops_basic_authentication'] = array("username" => "monty", "password" => "montyspw"); Take it step by step. Last edited by mariosipad; 05-22-2017 at 06:09 PM. |
05-22-2017, 07:05 PM | #1558 | |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Quote:
Copied the above verbatim, including password, and entered. Deleted the current config_local.monty.php I had. No change. [Edit] I just tried .htaccess in local mode and it is not kicking in. I used the one that came with the cops111 zip. Then I created a new .htpasswd with my monty name and password. If I leave the cops auth statement active in config_local.cfg, then I get the login form for cops that doesn't work. So I commented it out. Still using incognito mode, I entered 192.168.x.xxx/COPS111. It jumps right to the test library I have setup for the test; no password form from apache. I am pretty sure it worked in local mode before, but I am absolutely sure it worked when I used it through pagekite/Internet. Should it work locally? Did I mention I hate Apache...? I finally remembered that the basic apache.conf had to be modified for password protection through Apache. Here is what I now have, but it still isn't working: Code:
<Directory "/share/Web"> Options FollowSymLinks MultiViews AllowOverride All Require all granted AuthType Basic AuthName "RESTRICTED AREA" AuthUserFile /share/Web/COPS111/.htpasswd Require valid-user </Directory> Last edited by MontyJ; 05-22-2017 at 08:18 PM. Reason: Update |
|
05-23-2017, 12:45 PM | #1559 | |
Guru
Posts: 719
Karma: 10738
Join Date: Nov 2012
Device: iPad & iPhone with Marvin 2 + 3 & Kobo Glo HD
|
[I had some internet (ISP) problems today. Some sites like this one refused to load. Seems to be fixed now.]
1 - to use .htaccess you might need the AllowOverride All statement like you have now. 2 - I would slightly change the lines you put in apache.conf, but it should work like you have it now. Code:
<Directory "/share/Web/COPS111">
Options FollowSymLinks MultiViews
AllowOverride All
Require all granted
AuthType Basic
AuthName "RESTRICTED AREA"
AuthUserFile /share/Web/COPS111/.htpasswd
Require valid-user
</Directory>
This all probably explains (hopefully) why authentication did not work. I hope it does now. Quote:
while NGINX does not. Last edited by mariosipad; 05-23-2017 at 12:46 PM. Reason: typo |
|
05-23-2017, 02:05 PM | #1560 | |
Addict
Posts: 224
Karma: 10
Join Date: Jul 2012
Device: Kindle
|
Quote:
I still have the Apache setup, so will give your idea a try. But I relented and installed the latest QApache, which was what I was using before when I had cops in /share/htdocs. And, I actually had it working for two users, briefly, then I screwed something up. The last time I had it fully working, I had to put all the cops files in /share/htdocs. It appears the correct way is to have it in /share/htdocs/COPS111 and that is where I run into problems. But, working my way in the old learn-by-doing thing, LoL. Question: How does COPS save individual user settings? Cookies?? Because everytime I go back into a different user, the settings are all gone. They seem to stick if I don't clear the cache. If this is the case, it means the user cannot clear their local caches and delete cookies, right? Tell me it ain't so!! |
|
Tags |
calibre opds, dns, kobo aura, synology |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre OPDS server with windows apps? | nickdma | Related Tools | 10 | 03-03-2024 02:53 PM |
[Old Thread] Android FBreader and Calibre OPDS server question | kalex | Calibre | 5 | 12-24-2015 10:16 PM |
PHP+Apache web server for calibre ... | chaley | Related Tools | 254 | 04-28-2014 08:18 PM |
External OPDS catalogue in Calibre | bolton | Calibre | 1 | 09-05-2012 06:14 AM |
Calibre Command Line usage with PHP | artoros | Related Tools | 13 | 07-01-2010 09:57 AM |