Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
YouTube Security VideosTechLinked: MacOS 27 launch ain't looking so good(23.09.2026 um 21:00 Uhr)
YouTube Security VideosNeil Patel: Don't Just Be Right. Be Repeatable. #shorts(23.09.2026 um 20:04 Uhr)
YouTube Security VideosMicrosoft Mechanics: How to Share a Copilot Agent With Your Team(23.09.2026 um 20:30 Uhr)
Sicherheitslücken (CVE)USN-8806-1: NetworkManager vulnerability(23.09.2026 um 15:24 Uhr)
Sicherheitslücken (CVE)USN-8807-1: Open-iSNS vulnerability(23.09.2026 um 19:07 Uhr)
Unix & Linux ServerUSN-8808-1: SQL parse vulnerabilities(23.09.2026 um 20:19 Uhr)
YouTube Security VideosTechLinked: MacOS 27 launch ain't looking so good(23.09.2026 um 21:00 Uhr)
YouTube Security VideosNeil Patel: Don't Just Be Right. Be Repeatable. #shorts(23.09.2026 um 20:04 Uhr)
YouTube Security VideosMicrosoft Mechanics: How to Share a Copilot Agent With Your Team(23.09.2026 um 20:30 Uhr)
Sicherheitslücken (CVE)USN-8806-1: NetworkManager vulnerability(23.09.2026 um 15:24 Uhr)
Sicherheitslücken (CVE)USN-8807-1: Open-iSNS vulnerability(23.09.2026 um 19:07 Uhr)
Unix & Linux ServerUSN-8808-1: SQL parse vulnerabilities(23.09.2026 um 20:19 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

Connecting PostgreSQL on a Linux (WSL) Server to DBeaver

INTRODUCTION PostgreSQL is a relational database management system used to store and manage structured data. When installed inside Windows Subsystem for Linux (WSL), it runs in a Linux environment on a Windows machine.DBeaver is a…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!




INTRODUCTION



PostgreSQL is a relational database management system used to store and manage structured data. When installed inside Windows Subsystem for Linux (WSL), it runs in a Linux environment on a Windows machine.DBeaver is a graphical database management tool that supports PostgreSQL. Connecting DBeaver to PostgreSQL running in WSL allows users to manage the database using a nice visual interface instead of only terminal commands.



Prerequisites




  • PostgreSQL installed and running inside WSL

  • DBeaver installed on your Windows machine

  • Access credentials for the PostgreSQL user (e.g., postgres user and password)



STEP 1: Confirm Installation of PostgreSQL




  • To confirm if postgreSQL has been installed and is running in WSL, Inside the WSL terminal, enter the following command




psql --version






If installed, it displays the postgreSQL version




  • Then check if the service is running using the following command




sudo systemctl status postgresql







  • If it is not running, use the following command to start the service:




sudo systemctl start postgresql






STEP 2 : Create or Verify Database




  • After the postgres service is up and running,switch to the postgres account on your server:




sudo -i -u postgres







  • The following command will log you into the PostgreSQL prompt where you can interact with the database management system:




psql







  • Use the following command to show a list of databases available




\l







  • Suppose your database is not in the list, create one using the following command:




CREATE DATABASE <database_name>






NOTE: Replace the name with the required database name



STEP 3: Configure Authentication

By default, PostgreSQL on Ubuntu/WSL uses peer authentication, which works in the Linux terminal but does not work with external tools like DBeaver.Editing the method to md5 enables password-based authentication, allowing external tools to connect successfully.




  • To edit the authentication file, use the following commands:



cd /etc/postgresql/16/main 






then:




sudo nano pg_hba.conf







  • Find:
    local all postgres peer

    -Change it to:
    local all postgres md5


  • Also ensure these lines exist and are configured correctly:
    host all all 127.0.0.1/32 md5
    host all all ::1/128 md5


  • Save and restart PostgreSQL:




sudo service postgresql restart







STEP 4: Set a Password for the PostgreSQL User




  • Log into postgres on your server:




sudo -i -u postgres







  • Set the password:




ALTER USER postgres WITH PASSWORD 'yourpassword';








  • Save and exit:




\q






STEP 5: Configure PostgreSQL to Listen on All Interfaces

By default, PostgreSQL listens only on localhost.

In WSL 2, this may prevent DBeaver (running in Windows) from connecting properly because WSL operates on a separate virtual network interface.




  • Edit the configuration file:




sudo nano /etc/postgresql/*/main/postgresql.conf







  • Find:
    listen_addresses = 'localhost'

    -Change it to:
    listen_addresses = '*'

  • Save and restart PostgreSQL



STEP 6: Obtain the WSL IP Address




  • In WSL, run:




ip addr show eth0







  • Find:




inet 172.xx.xx.xx/xx






*NOTE:This will be the value used as the host in DBeaver. *



STEP 7: Connect Using DBeaver




  • Open DBeaver, create a new PostgreSQL connection.

  • Fill in with the details of your connection



connection page in dbeaver




  • SSL tab:
    Set SSL mode to Disable

  • Click Test Connection.



If configured correctly, the connection should succeed.Click Finish.






CONCLUSION



Connecting PostgreSQL running inside WSL to DBeaver allows users to manage their database using a graphical interface instead of relying only on terminal commands. By configuring authentication, setting a password, adjusting the listen address, and using the correct WSL IP address, the connection can be established successfully. This setup makes it easier to run queries, manage tables, and work with databases more efficiently.

CTI Threat Relationship Graph2 Knoten / 1 Relationen
CVE / Incident Software MITRE ATT&CK CWE Weakness IoC
IR-PLAYBOOK-VULN-REMEDIATION
MEDIUM
SOC Incident Playbook: Vulnerability Remediation & Verification
1-Click Detection Engineering: Sigma & YARA Rules
SOC Ready
title: Detect Exploitation - Connecting PostgreSQL on a Linux (WSL) Server to DBeaver
id: cd342e6d-35a7-42c3-9436-3cecb661537f
status: experimental
description: Automatisch generierte SIEM-Erkennungsregel basierend auf CTI Intelligence
references:
  - https://tsecurity.de/
author: iShareStuff CTI Automated Detection Engine
date: 2026-09-23
logsource:
  category: network_connection
  product: any
detection:
  selection:
      CommandLine|contains:
        - 'exploit'
  condition: selection
falsepositives:
  - Legitime administrative Zugriffe oder Penetrationstests
level: high
tags:
  - attack.initial_access
rule CTI_Threat_Indicator {
    meta:
        author = "iShareStuff CTI Automated Detection Engine"
        date = "2026-09-23"
        description = "YARA Signature for "
    strings:
        $str = "Connecting PostgreSQL on a Lin" ascii wide
    condition:
        any of them
}
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Connecting PostgreSQL on a Linux (WSL) Server to DBeaver

Thematisch verwandte Begriffe: Connecting, PostgreSQL, Linux, Server · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-90904 | Joomla Extension - joomshaper.com - Broken Access Control (ACL Bypass) i…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel TTP ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick