Banshee
the secure PHP framework

Forum

Banshee 6 Fresh Install Yields Non-stop cms 401s

Michaelv2
18 march 2017, 22:21
Greetings! I'm running the new version of Banshee on the latest Hiawatha, (Debian Stretch) but after setup, I'm getting constant login screens between each page in the CMS. I've double-checked my Hiawatha (including the banshee update on URLToolKit) and php-fpm confs, but nothing jumps out at me. I removed and reinstalled (complete with new demo db creation and db-user), but I still get the same.

I can progress and view admin pages, but I must re-enter username and password for each page, which also prevents a successful settings update. There are no 403s or incorrect login msgs...just the constant 401s. Anyone have any idea what would cause auth to drop like that? MySQL and PHP logs aren't providing clues and the browser/browser configs aren't the culprit. Is this a session/db issue or am I looking in the wrong place?
MNicole
19 march 2017, 17:19
Hi.

You have the same that I've got ... :-(
See my previous "auto -logout" message.

I did'nt yet resolve this.
With also hiawatha 10-3/4/5.
Compiled by me. All installations I've made very clean.

It's annoying, because everything else is running perfectly well, Hiawatha an Banshee are top tools, in my opinion ...

The only solution I've found: clean all the cookies, the browser cache, and of course re-login, and with luck, it goes ok for some time ...

Michaelv2
23 march 2017, 09:23
I understand your frustration and agree...Hiawatha and Banshee seem great to me, even if they require a little extra work to integrate with other packages. At any rate, I was hoping to avoid posting logs and configs--I love fixing things myself...I was just curious if anyone could narrow down these symptoms to a specific fundamental area.

I'll post back if I find a workaround or fix, but it may be a week or two so I complete some other work for a client.
MNicole
14 june 2017, 14:05
Hi again.

Didn't you seee something about this problem I called "auto logout" ?

I've been recently in many details in CMFs, but for this, I did not see yet what it is.
And I like Banshee, so it would be a pity I don't use it because this.

So if you have some news ?
Regards.

Joe Schmoe
14 june 2017, 19:03
Someone recently mentioned that they fixed a similar problem by setting cgi.fix_pathinfo to 1.

https://www.banshee-php.org/forum/topic/189
Hugo Leisink
14 june 2017, 22:09
Does the client get a new session cookie with every request? If so, can the cookie be stored in the database correctly? Enough room in the varchar?
MNicole
15 june 2017, 14:25
Thanks to everybody for replies.

-- For the < cgi.fix_pathinfo > php parameter,
yes, seen at the time, tried, no change.

-- Generally speaking.
I got this with Banshee #2/3/4.
I went into php source files for looking, but never modified one.
I modified *.css and *.xslt only.
For the database, with each version, each time I recreated it with the original dump sql file (Mysql and MariaDB, both used/tried).
I always check very carefully the running, with debug flag "on".
I want no error at all. It's what I have, despite this problem.

So now, practically, the question is, for me ...
Ok, I go deeper into the *.php sources, and of course, soon or later, I'll found the problem ...
But seen the clean code, until now I avoided this.

So, I do not know ... :-)
Hugo Leisink
15 june 2017, 14:37
If you provide me with an URL and a login for a dummy website, perhaps I can help.
MNicole
15 june 2017, 14:48

For info, an extract of my Database structure =>

--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`session_id` varchar(100) NOT NULL,
`login_id` varchar(100) DEFAULT NULL,
`content` text,
`expire` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`user_id` int(10) unsigned DEFAULT NULL,
`ip_address` varchar(50) NOT NULL,
`bind_to_ip` tinyint(1) NOT NULL,
`name` tinytext,
PRIMARY KEY (`id`),
UNIQUE KEY `session_id` (`session_id`),
KEY `user_id` (`user_id`),
CONSTRAINT `sessions_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=706 DEFAULT CHARSET=utf8;


--
-- Extract dump for table `settings`
--

... (42,'session_timeout','integer','1200'), (43,'session_persistent','boolean','true') ...

MNicole
15 june 2017, 14:54
Oh, nice, Hugo.

A "non dummy" site is :
< https://ikarion.org > (or http://..)
User < ikguest >
Pwd < xx-ik-guest >

(Note: the problem I have, it's always with < admin >)

Hugo Leisink
15 june 2017, 14:59
That one works without a problem. I wasn't aware it's an admin-only issue. That makes it strange, cause an admin is not handled differently in terms of login. Can you setup a dummy website to which you can give me admin access?
MNicole
15 june 2017, 17:01

Thanks a lot, Hugo.

In fact, I said "only with admin" because I have no experience with other accounts, I always use "admin" (or nobody; and sometimes, a try as some user).
But I thought what you said, that admin is not handled differently.

I tried also before, "ikguest", no problem.
And "admin", idem. But not surprised, because sometimes the "admin" login stays ok for sometime. It's often when I edit a page, for example, that it begins ... :-(

Just a note. I use Firefox browser. But I do not think it's it, and I tried also in the past other browsers, precisely for this problem. Same.

I have no "dummy" website ...
But later, I can put the same Banshee on my other node < ikarion.net >.
A better node, because it's a VPS where I control everything (Debian #8; with Hiawatha #10.6, among others tools).
And I can give you an admin access. But not through this Forum :-)

Hugo Leisink
19 june 2017, 19:54
If you still need some help with this, send the admin credentials to me by e-mail.
Julia
23 september 2017, 16:16
Hello Everyone,

Anyone can help me what folder i put this following code:

-------
UrlToolkit {
ToolkitID = banshee
RequestURI isfile Return
Match ^/(css|files|fonts|images|js)(/|$) Return
Match ^/(favicon.ico|robots.txt)$ Return
Match [^?]*(\?.*)? Rewrite /index.php$1
}

AND

--
cgi.fix_pathinfo = 0 (when using FastCGI PHP), 1 (otherwise)
cgi.rfc2616_headers = 1 (when using Hiawatha) / 0 (when using Apache)
register_globals = Off
allow_url_include = Off

Please Reply I need to know
Thanks
Hugo Leisink
23 september 2017, 16:19
The UrlToolkit goes into your Hiawatha configuration file. The stuff below 'AND' are PHP configuration options and must be placed in php.ini (not all options are valid for PHP7).
Message preview

The following BB-codes are available in a message:

  • [b]Bold text[/b]
  • [center]Center text or imagen[/center]
  • [color=color name or #RGB code]Colored text[/color]
  • [i]Italic text[/i]
  • [img]Link to image[/img]
  • [right]Align text or image right[/right]
  • [s]Strike-through text[/s]
  • [size=pixelsize]Big or small text[/size]
  • [u]Underlined text[/u]
  • [url]Link to website[/url]
  • [url=link to website]Link text[/url]