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

Bookmarks with no passwords #652

Open
dani opened this issue Feb 22, 2023 · 6 comments
Open

Bookmarks with no passwords #652

dani opened this issue Feb 22, 2023 · 6 comments

Comments

@dani
Copy link

dani commented Feb 22, 2023

Hi.

Since pgweb 0.13, bookmarks with no password defined aren't working anymore (it was OK in 0.12).

I'm running pgweb with the following args

opt/pgweb/bin/pgweb \
             --listen 8086 \
             --bind 127.0.0.1 \
             --bookmarks-dir=/opt/pgweb/bookmarks \
             --no-ssh \
             --sessions \
             --skip-open \
             --readonly

In /opt/pgweb/bookmarks, I create files like

host = "localhost"
database = "appdb"
port = 5432
user = "fr00000113"

The idea is to have host, db, user preconfigured when selecting the bookmark, but I must manually enter the DB password.

Since 0.13.0 (and still in 0.14.0), when selecting a bookmark, all the fields are greyed out, so I cannot enter the password anymore

image

@sosedoff
Copy link
Owner

sosedoff commented Feb 22, 2023 via email

@dani
Copy link
Author

dani commented Feb 22, 2023

I need users to enter the DB password to access it (that's how users are authenticated)

@dani
Copy link
Author

dani commented Feb 22, 2023

If the bookmark has no password, shouldn't the password field of the welcome page be available ?

@sosedoff
Copy link
Owner

If the bookmark is missing the password it's not really a bookmark, ie no one can actually use it without knowing the password. But i understand your point of view regarding the missing field, so we could fix that in future releases.

What is your use case and how are you running Pgweb? If you're running Pgweb for internal users that need access to various DB resources, you could take a look at https://github.com/sosedoff/pgweb/wiki/Connect-Backend - it was designed to eliminate the use of credentials for multi-session setups.

@dani
Copy link
Author

dani commented Feb 22, 2023

Bookmarks are still useful to pre-fill all the other parameters. My use case is an application appliance, using various postgres databases. Pgweb is exposed by an nginx frontend with no authentication itself, so even if the appliance is usually not exposed to the outside, not everyone having network access should be able to browse the databases. Only admins (tech profiles, having the postgres DB should). I could probably write a connect backend, but bookmarks (without password) was just enough for my use case until 0.13.0

@NeckBeardPrince
Copy link

Is this still a limitation in the newer releases? I have the same use case as @dani.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants