Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenCTI should be able to use password with only numbers in it #208

Closed
Serrvosky opened this issue Sep 4, 2019 · 4 comments
Closed

OpenCTI should be able to use password with only numbers in it #208

Serrvosky opened this issue Sep 4, 2019 · 4 comments
Assignees
Labels
bug use for describing something not working as expected solved use to identify issue that has been solved (must be linked to the solving PR)
Milestone

Comments

@Serrvosky
Copy link

Please replace every line in curly brackets { like this } with an appropriate answer, and remove this line.

Description

I just start OpenCTI by docker installation, and when I try to login it fails giving this response:

{"errors":[{"message":"Wrong name or password","name":"AuthenticationFailure","time_thrown":"2019-09-04T13:22:03.470Z","data":{"type":"business"}}],"data":{"token":null}}
I change docker-compose file env vars:
- APP__ADMIN__EMAIL=[email protected]
- APP__ADMIN__PASSWORD=123123123

I

Environment

  1. Ubuntu Server
  2. OpenCTI version: 1.1.1
  3. OpenCTI client: ??
  4. Other environment details:

Reproducible Steps

Steps to create the smallest reproducible scenario:
All the step indicated in the documentation:
https://opencti-platform.github.io/docs/installation/docker

Expected Output

Success on login page

Actual Output

Failed login

@richard-julien
Copy link
Member

Really strange error. Can you attach your docker compose file on this ticket?

@Serrvosky
Copy link
Author

version: '3'
services:
  grakn:
    image: graknlabs/grakn:1.5.7
    ports:
      - 48555:48555 
    volumes:
      - grakndata:/grakn-core-all-linux/server/db
    restart: always
  redis:
    image: redis:5.0.5
    restart: always
  elasticsearch:
    image: docker.elastic.co/elasticsearch/elasticsearch:7.3.0
    volumes:
      - esdata:/usr/share/elasticsearch/data
    environment:
      - discovery.type=single-node
    restart: always
    ulimits:
      memlock:
        soft: -1
        hard: -1
      nofile:
        soft: 65536
        hard: 65536
  rabbitmq:
    image: rabbitmq:3.7.17-management
    environment:
      - RABBITMQ_DEFAULT_USER=guest
      - RABBITMQ_DEFAULT_PASS=guest    
    restart: always
  opencti:
    image: opencti/platform:1.1.1
    environment:
      - APP__PORT=8080
      - [email protected]
      - APP__ADMIN__PASSWORD=123123123
      - APP__ADMIN__TOKEN=de42fdb8-267b-499f-b9bf-77be0d286dde
      - APP__LOGS=./logs
      - APP__REACTIVE=true
      - APP__COOKIE_SECURE=false
      - GRAKN__HOSTNAME=grakn
      - GRAKN__PORT=48555
      - GRAKN__TIMEOUT=30000
      - REDIS__HOSTNAME=redis
      - REDIS__PORT=6379
      - ELASTICSEARCH__URL=http://elasticsearch:9200
      - RABBITMQ__HOSTNAME=rabbitmq
      - RABBITMQ__PORT=5672
      - RABBITMQ__PORT_MANAGEMENT=15672
      - RABBITMQ__MANAGEMENT_SSL=false
      - RABBITMQ__USERNAME=guest
      - RABBITMQ__PASSWORD=guest
    ports:
      - "8080:8080"
    depends_on:
      - grakn
      - redis
      - elasticsearch
      - rabbitmq
    restart: always
  worker-import:
    image: opencti/worker:1.1.1
    environment:
      - WORKER_TYPE=import
      - WORKER_LOG_LEVEL=info
      - OPENCTI_URL=http://opencti:8080
      - OPENCTI_TOKEN=de42fdb8-267b-499f-b9bf-77be0d286dde
      - RABBITMQ_HOSTNAME=rabbitmq
      - RABBITMQ_PORT=5672
      - RABBITMQ_PORT_MANAGEMENT=15672
      - RABBITMQ_MANAGEMENT_SSL=false
      - RABBITMQ_USERNAME=guest
      - RABBITMQ_PASSWORD=guest
    depends_on:
      - opencti
    deploy:
      mode: replicated
      replicas: 4
    restart: always
  worker-export:
    image: opencti/worker:1.1.1
    environment:
      - WORKER_TYPE=export
      - WORKER_LOG_LEVEL=info
      - OPENCTI_URL=http://opencti:8080
      - OPENCTI_TOKEN=de42fdb8-267b-499f-b9bf-77be0d286dde
      - RABBITMQ_HOSTNAME=rabbitmq
      - RABBITMQ_PORT=5672
      - RABBITMQ_PORT_MANAGEMENT=15672
      - RABBITMQ_MANAGEMENT_SSL=false
      - RABBITMQ_USERNAME=guest
      - RABBITMQ_PASSWORD=guest
    depends_on:
      - opencti
    deploy:
      mode: replicated
      replicas: 2      
    restart: always
  connector-opencti:
    image: opencti/connector-opencti:1.1.2
    environment:
      - RABBITMQ_HOSTNAME=rabbitmq
      - RABBITMQ_PORT=5672 
      - RABBITMQ_USERNAME=guest
      - RABBITMQ_PASSWORD=guest
      - OPENCTI_NAME=OpenCTI
      - OPENCTI_CONFIDENCE_LEVEL=5
      - OPENCTI_SECTORS_FILE_URL=https://raw.githubusercontent.com/OpenCTI-Platform/datasets/master/data/sectors.json
      - OPENCTI_ENTITIES=identity,sector,region,country,city
      - OPENCTI_INTERVAL=1 # Days
      - OPENCTI_LOG_LEVEL=info
    depends_on:
      - opencti
    restart: always
  connector-mitre:
    image: opencti/connector-mitre:1.1.2
    environment:
      - RABBITMQ_HOSTNAME=rabbitmq
      - RABBITMQ_PORT=5672 
      - RABBITMQ_USERNAME=guest
      - RABBITMQ_PASSWORD=guest
      - MITRE_NAME=MITRE\ ATT&CK
      - MITRE_CONFIDENCE_LEVEL=3
      - MITRE_ENTERPRISE_FILE_URL=https://raw.githubusercontent.com/mitre/cti/master/enterprise-attack/enterprise-attack.json
      - MITRE_ENTITIES=identity,attack-pattern,course-of-action,intrusion-set,malware,tool
      - MITRE_INTERVAL=7 # Days
      - MITRE_LOG_LEVEL=info    
    depends_on:
      - opencti
    restart: always            
volumes:
  grakndata:
  esdata:

@richard-julien
Copy link
Member

Hi @Serrvosky, after looking into your problem, the solution is to change your password with something that is not only numbers 🔢 ... The code doesn't force the password in string and fail in the crypto function because its considered as a number. I think if you change the password to test123123123 it will works.

I will change the definition of your bug and fix it for the next release

@richard-julien richard-julien changed the title Authentication failed on docker setup OpenCTI should be able to use password with only numbers in it Sep 4, 2019
@richard-julien richard-julien self-assigned this Sep 4, 2019
@richard-julien richard-julien added the bug use for describing something not working as expected label Sep 4, 2019
@richard-julien richard-julien added this to the Release 1.1.2 milestone Sep 4, 2019
@Serrvosky
Copy link
Author

It works. Thanks.

@SamuelHassine SamuelHassine added the solved use to identify issue that has been solved (must be linked to the solving PR) label Sep 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug use for describing something not working as expected solved use to identify issue that has been solved (must be linked to the solving PR)
Projects
None yet
Development

No branches or pull requests

3 participants