CanciuCostin / android-spyware

Rails c&c web application for spying Android devices
MIT License
535 stars 142 forks source link

PG::ConnectionBad #46

Open JayMwakideu opened 2 years ago

JayMwakideu commented 2 years ago

fe_sendauth: no password supplied

Extracted source (around line #58):
56 57 58 59 60 61 | ### Convenience alias for PG::Connection.new. def self::connect( *args ) return PG::Connection.new( *args ) end -- | --

Rails.root: C:/Windows/system32/android-spyware

CanciuCostin commented 2 years ago

Is this error thrown on Docker deployment? Or after build? What is the OS?

JayMwakideu commented 2 years ago

after build,

JayMwakideu commented 2 years ago

ADB connection to be exact

CanciuCostin commented 2 years ago

Seems that you are not connected to the postgresdb. Not sure if you've configured a local instance or not.

You can try to run the postgres and msf instances from docker and keep your rails instance locally for build. Try to set these environment variables:

ANDROIDSPYWARE_DATABASE_HOST=localhost
ADB_HOST=localhost
RAILS_HOST=127.0.0.1

and run docker-compose up after commenting the rails service

version: "3.7"
services:
#  rails-app:
#    image: costincanciu/android-spyware:latest
#    depends_on:
#      - db
#      - metasploit
#    ports:
#      - "80:80"
#    volumes:
#      - ./files:/app/android-spyware/files
#      - //var/run/docker.sock://var/run/docker.sock
#    entrypoint: sh -c "mkdir -p /app/android-spyware/files/payloads /app/android-spyware/files/dumps/calllogs_dumps /app/android-spyware/files/dumps/contacts_dumps /app/android-spyware/files/dumps/microphone_recs /app/android-spyware/files/dumps/pictures /app/android-spyware/files/dumps/screen_snaps /app/android-spyware/files/dumps/sms_messages_dumps /app/android-spyware/files/dumps/whatsapp | rails s -b 0.0.0.0 -p 80"
#    tty: true
#    environment:
#      ADB_HOST: gateway.docker.internal
#      #MAPS_API_KEY: YOUR KEY HERE
  db:
    image: costincanciu/android-spyware-db:latest
    ports:
      - "5432:5432"
    volumes:
      - db:/var/lib/postgresql/data
    environment:
      POSTGRES_HOST_AUTH_METHOD: trust
  metasploit:
    container_name: kali_container
    image: costincanciu/android-spyware-msf:latest
    ports:
    - "2222:2222"
    - "3333:3333"
    - "4444:4444"
    user: root
volumes:
  db:
JayMwakideu commented 2 years ago

Thanks mate, let me try

On Fri, Nov 12, 2021, 10:21 Canciu Costin @.***> wrote:

Seems that you are not connected to the postgresdb. Not sure if you've configured a local instance or not.

You can try to run the postgres and msf instances from docker and keep your rails instance locally for build. Try to set these environment variables:

ANDROIDSPYWARE_DATABASE_HOST=localhost ADB_HOST=localhost RAILS_HOST=127.0.0.1

and run docker-compose up after commenting the rails service

version: "3.7" services:

rails-app:

image: costincanciu/android-spyware:latest

depends_on:

- db

- metasploit

ports:

- "80:80"

volumes:

- ./files:/app/android-spyware/files

- //var/run/docker.sock://var/run/docker.sock

entrypoint: sh -c "mkdir -p /app/android-spyware/files/payloads /app/android-spyware/files/dumps/calllogs_dumps /app/android-spyware/files/dumps/contacts_dumps /app/android-spyware/files/dumps/microphone_recs /app/android-spyware/files/dumps/pictures /app/android-spyware/files/dumps/screen_snaps /app/android-spyware/files/dumps/sms_messages_dumps /app/android-spyware/files/dumps/whatsapp | rails s -b 0.0.0.0 -p 80"

tty: true

environment:

ADB_HOST: gateway.docker.internal

MAPS_API_KEY: YOUR KEY HERE

db: image: costincanciu/android-spyware-db:latest ports:

  • "5432:5432" volumes:
  • db:/var/lib/postgresql/data environment: POSTGRES_HOST_AUTH_METHOD: trust metasploit: container_name: kali_container image: costincanciu/android-spyware-msf:latest ports:
    • "2222:2222"
    • "3333:3333"
    • "4444:4444" user: root volumes: db:

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/CanciuCostin/android-spyware/issues/46#issuecomment-966880753, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEY5PRFFGPCUBOOYR3F2FFDULS567ANCNFSM5HQYBRTA .