TheHive-Project / TheHive

TheHive: a Scalable, Open Source and Free Security Incident Response Platform
https://thehive-project.org
GNU Affero General Public License v3.0
3.34k stars 613 forks source link

[Bug] User superadmin not working MIGRATE BD. #1266

Open dtokkk opened 4 years ago

dtokkk commented 4 years ago

Request Type

Bug

Work Environment

Question Answer
OS version (server) Ubuntu
OS version (client) Ubuntu
TheHive version / git hash 4RC1
Package Type DEB
Browser type & version Chrome, Firefox

Problem Description

After using the migrate script (BD from ElasticSearch to Cassandra) the superadmin "freeze" user after login (you can't navigate in TheHive).

Steps to Reproduce

  1. Migrate the DB. /opt/thehive/bin/migrate \ --output /etc/thehive/application.conf \ --main-organisation CSIRT \ --es-uri http://127.0.0.1:9200

  2. Login with superadmin user admin@thehive.local / secret

Complementary information

Logs

2020-03-22 20:53:14,107 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-28 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:14,260 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-28 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:14,372 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-11 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:14,532 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-21 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:14,653 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-19 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:14,794 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-11 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:14,939 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-27 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:15,078 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-26 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:15,197 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-18 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:15,325 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-21 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:53:15,474 [WARN] from org.thp.scalligraph.query.InputFilter in application-akka.actor.default-dispatcher-18 - Use of filter {"owner": "FString(admin@thehive.local)"} is deprecated. Please use {"_is":{"owner":"FString(admin@thehive.local)"}} 2020-03-22 20:55:39,059 [WARN] from org.thp.scalligraph.ErrorHandler in application-akka.actor.default-dispatcher-26 - GET /api/v1/user/admin@thehive.local returned 404 2020-03-22 20:55:39,062 [INFO] from org.thp.scalligraph.AccessLogFilter in application-akka.actor.default-dispatcher-26 - 192.168.0.200 GET /api/v1/user/admin@thehive.local took 115ms and returned 404 55 bytes 2020-03-22 20:55:53,449 [WARN] from org.thp.scalligraph.ErrorHandler in application-akka.actor.default-dispatcher-28 - GET /api/v1/user/admin@thehive.local returned 404 2020-03-22 20:55:53,450 [INFO] from org.thp.scalligraph.AccessLogFilter in application-akka.actor.default-dispatcher-28 - 192.168.0.200 GET /api/v1/user/admin@thehive.local took 38ms and returned 404 55 bytes

To-om commented 4 years ago

What do you mean by "the superadmin "freeze" user after login" ? Can you try 4.0.0-RC2 ?

joseluratm commented 4 years ago

Same problem here. When trying to migrate from my thehive 3.4.2 to thehive 4.0.0-rc1, I had to stop the process. I have launched it again, and the admin user tells me that authentication failed.