View ProjeQtOr On SourceForge.net
ProjeQtOr - Project Management Tool
Support us on Capterra
OIN - Open Invention Network
ProjeQtOr free project management software - Existing login not recognized anymore after Server resinstalled - ProjeQtOr
 
 

Existing login not recognized anymore after Server resinstalled

More
06 Jan 2022 00:29 #1 by INX-EXLOG
Hi Team , 

First of all : thanks for the great work you are doing.  
Aficionado of this tool I am using from years.

Let's see if you can help me regarding this tricky issue ..

With a docker Infra :
Automatic install (dockerfile)
I installed the app on a linux:nginx stack >> no issues  (debian+nginx+php8.0+ modules )
I installed the DB (Maria)   >> no issues

No problem installing and initiating the app .
Using the app a couple of weeks . No issues (as usual) 

Then decided to test the redeploy process.
ACT I
 when I dropped  the server to reinstall it (deleting the pod and automatically redeploying  the image) :
- server started fine 
- login page is displayed 
OOOOOhhh   ---   no former login recognized anymore   (same db : the one not been touched)

>> from the logs  : the $expected   <> $password    

ACT II
I dumped the db .

I truncated the db schema.

I refreshed the app (the reinstalled one , not allowing a login ) and then started the install process (admin/admin)
No issues : the app is now accessible -- but empty.
I changed the admin password and was able to disconnect and reconnect the app as many times as needed.

ACT III
From here 
I truncated the ACT II dB  and reloaded the ACT I dumped db  (the one with the real data into it).

FINAL CUT
From here I was able to run the reinstalles projeqtor app with the former dB content .


>>>> Isn't it too many steps to  be able to re run a redeployed image ?

My first thought was to make sure cookie/cache were empty .
And when I discovered I could rerun the app by running a "fake" 1st install ... I decided to send you this post .

Long story telling , but longer  "try and error" hours I spent.

Anyone experienced  such issue ??? 

Regards





 

Please Log in or Create an account to join the conversation.

More
07 Jan 2022 16:15 #2 by babynus
Hi,

Never faced such issue, but I don't use docker image...
Maybe issue comes form Cookie/Caching on your browser side.
On ACT I, possibly connecting with another browser could work.
If it does not work and you still get login issue, you can try to udate DB, talbe resource, set password = "new password in clear text", crypto = null
You'll be able to connect with new password and will have to change it at first connection

Babynus
Administrator of ProjeQtOr web site

Please Log in or Create an account to join the conversation.

More
07 Jan 2022 21:52 - 07 Jan 2022 22:07 #3 by INX-EXLOG
Hi babynus, 
thanks for the advices . Unfortunately the cache/cookie cleaning is not solving the issue.

The proposed workaround works perfecly for few users but imagine resetting hundreds accounts with a sql default password and ressetting the crypto algo.
..a nightmare ..

As during the investigation (ACT III) I cleaned the DB  >>> launched the install process  >>> changed the admin default password .
                                                       and after reloaded the productive db (with real data and not defaulted password) 
                                                     >>> and from it , the system was able to recognize the former passwords , I suspect there is  something 
                                                             in the logincheck logic that forbids a fresh new system install image from reading the "salt" from the db for the username trying to login.
                                                          
        Does this lead makes sense ?


Hope these information could help finding where there is a fix or a workaround (not the one I have been through ... which is more than painful )

Regards



 
Last edit: 07 Jan 2022 22:07 by INX-EXLOG.

Please Log in or Create an account to join the conversation.

More
10 Jan 2022 09:33 #4 by babynus
Hi,

Does this lead makes sense ?

Unfortunately this is out of my competencies.
I'am almost sure it is not a projeqtor issue but a docker image management issue.
Possibly linked to encoding ? Check if install from image correctly displays accentuated characters.

Babynus
Administrator of ProjeQtOr web site

Please Log in or Create an account to join the conversation.

More
12 Jan 2022 19:19 - 12 Jan 2022 22:02 #5 by INX-EXLOG
Hello 

i did a fix into the code to handle this bizarre behaviour :
I still do not know what is the real cause of it and why this happens and disappears when doing this strange delete the table content+ reinstall+ drop the content  etc ...

During the logincheck process , after the docker app image reinstalled , I tracked the content of the variable which is "echoed" and sent to the 
crypto(data) function   (file /view/js/projeqtor.js) : changeIMade
the data variable which is supposed to be made of "crypto;usersalt; sessionsalt"   has a space character as  it 1st  position 
                                                                         thus " crypto;usersalt; sessionsalt"  is splitted in chunks  and the crypto method
not recognized anymore "sha256" expected vs " sha256" received.

As a result the crypto hash produced will differ from the one retrieved from the database.

Change I made is to trim the data variable : >> trim the data variable (any other method will work , I wrote this one to be very visible in the code.
(file /view/js/projeqtor.js)
function cryptData(data) {
  var changeIMade = trim(data);
  var arr = changeImade.split(';');


Now it's OK , I can drop and redrop the app docker image without any issue when login .

Just for your information :
in order to use a docker image like this (automatic restore & restart) you need to provide the parameter.php file config already filled.

I will spend a couple of hours trying to reproduce it with a standard LA(m)P stack   (will not install mysql on same machine) to see if this a docker image side effect , or something else.   

Thanks 
 
Last edit: 12 Jan 2022 22:02 by INX-EXLOG.

Please Log in or Create an account to join the conversation.

More
14 Jan 2022 09:09 #6 by babynus
Hi,

Thanks for your analysis.
Weid behavior, really...

We'll apply your fix on V9.4.2

Babynus
Administrator of ProjeQtOr web site

Please Log in or Create an account to join the conversation.

Moderators: babynusprotion
Time to create page: 0.043 seconds

Cookies settings

×

Functional Cookies

Ce site utilise des cookies pour assurer son bon fonctionnement et ne peuvent pas être désactivés de nos systèmes. Nous ne les utilisons pas à des fins publicitaires. Si ces cookies sont bloqués, certaines parties du site ne pourront pas fonctionner.

Session

Please login to see yours activities!

Other cookies

Ce site web utilise un certain nombre de cookies pour gérer, par exemple, les sessions utilisateurs.