iOS bitwardenrs/server:raspberry 2.12.1 cannot connect #583

Closed
opened 2026-02-04 21:39:52 +03:00 by OVERLORD · 2 comments
Owner

Originally created by @bigtarget on GitHub (Jan 30, 2020).

Hello,

I cannot connect with latest mobile app. Chrome plugin is working fine and web based valut.

I have generated certificate like described there: https://github.com/dani-garcia/bitwarden_rs/wiki/Private-CA-and-self-signed-certs-that-work-with-Chrome and using apache as a reverse proxy

<VirtualHost *:443>
    ServerName xxxxxxxxxxxxxxxxx
    ServerAlias xxxxxxxxxxxxx
    SSLEngine on
        SSLCertificateFile    /etc/apache2/ssl/bitwarden.crt
        SSLCertificateKeyFile /etc/apache2/ssl/bitwarden.key
        SSLCACertificateFile    /etc/apache2/ssl/self-signed-ca-cert.crt
    SSLProxyEngine On

 RewriteEngine On
    RewriteCond %{HTTP:ewriteCondwebsocket [NC]
    RewriteRule /notifications/hub(.*) ws://<SERVER>:3012/$1 [P,L]
    ProxyPass / http://localhost:80/

    ProxyPreserveHost On
    ProxyRequests Off
    RequestHeader set X-Real-IP %{REMOTE_ADDR}s
 ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

Getting message there is a problem connecting to the server.

I cannot open that bitwarden page with Safari as well, should i somehow add that certificate to iPhone?

Thank you.

Originally created by @bigtarget on GitHub (Jan 30, 2020). Hello, I cannot connect with latest mobile app. Chrome plugin is working fine and web based valut. I have generated certificate like described there: https://github.com/dani-garcia/bitwarden_rs/wiki/Private-CA-and-self-signed-certs-that-work-with-Chrome and using apache as a reverse proxy ``` <VirtualHost *:443> ServerName xxxxxxxxxxxxxxxxx ServerAlias xxxxxxxxxxxxx SSLEngine on SSLCertificateFile /etc/apache2/ssl/bitwarden.crt SSLCertificateKeyFile /etc/apache2/ssl/bitwarden.key SSLCACertificateFile /etc/apache2/ssl/self-signed-ca-cert.crt SSLProxyEngine On RewriteEngine On RewriteCond %{HTTP:ewriteCondwebsocket [NC] RewriteRule /notifications/hub(.*) ws://<SERVER>:3012/$1 [P,L] ProxyPass / http://localhost:80/ ProxyPreserveHost On ProxyRequests Off RequestHeader set X-Real-IP %{REMOTE_ADDR}s ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined </VirtualHost> ``` Getting message there is a problem connecting to the server. I cannot open that bitwarden page with Safari as well, should i somehow add that certificate to iPhone? Thank you.
Author
Owner

@bigtarget commented on GitHub (Jan 30, 2020):

Step to get certificate:

cd /etc/apache2/ssl/
openssl genpkey -algorithm RSA -aes128 -out private-ca.key -outform PEM -pkeyopt rsa_keygen_bits:2048
openssl req -x509 -new -nodes -sha256 -days 3650 -key private-ca.key -out self-signed-ca-cert.crt  -subj "/C=PL/ST=City/L=City/O=Domek/OU=IT Department/CN=xxxxxx"
openssl genpkey -algorithm RSA -out bitwarden.key -outform PEM -pkeyopt rsa_keygen_bits:2048
openssl req -new -key bitwarden.key -out bitwarden.csr -subj "/C=PL/ST=City/L=City/O=Domek/OU=IT Department/CN=xxxxxx"
openssl x509 -req -in bitwarden.csr -CA self-signed-ca-cert.crt -CAkey private-ca.key -CAcreateserial -out bitwarden.crt -days 365 -sha256 -extfile bitwarden.ext

bitwarden.ext

authorityKeyIdentifier=keyid,issuer
basicConstraints=CA:FALSE
keyUsage = digitalSignature, nonRepudiation, keyEncipherment, dataEncipherment
extendedKeyUsage = serverAuth
subjectAltName = @alt_names

[alt_names]
DNS.1 = xxxx.eu
DNS.2 = *.xxxxx.eu
@bigtarget commented on GitHub (Jan 30, 2020): Step to get certificate: ``` cd /etc/apache2/ssl/ openssl genpkey -algorithm RSA -aes128 -out private-ca.key -outform PEM -pkeyopt rsa_keygen_bits:2048 openssl req -x509 -new -nodes -sha256 -days 3650 -key private-ca.key -out self-signed-ca-cert.crt -subj "/C=PL/ST=City/L=City/O=Domek/OU=IT Department/CN=xxxxxx" openssl genpkey -algorithm RSA -out bitwarden.key -outform PEM -pkeyopt rsa_keygen_bits:2048 openssl req -new -key bitwarden.key -out bitwarden.csr -subj "/C=PL/ST=City/L=City/O=Domek/OU=IT Department/CN=xxxxxx" openssl x509 -req -in bitwarden.csr -CA self-signed-ca-cert.crt -CAkey private-ca.key -CAcreateserial -out bitwarden.crt -days 365 -sha256 -extfile bitwarden.ext ``` bitwarden.ext ``` authorityKeyIdentifier=keyid,issuer basicConstraints=CA:FALSE keyUsage = digitalSignature, nonRepudiation, keyEncipherment, dataEncipherment extendedKeyUsage = serverAuth subjectAltName = @alt_names [alt_names] DNS.1 = xxxx.eu DNS.2 = *.xxxxx.eu ```
Author
Owner

@bigtarget commented on GitHub (Jan 31, 2020):

I have solved issue with generating certificate with lets encrypt certbot certonly -d mydomain.com

@bigtarget commented on GitHub (Jan 31, 2020): I have solved issue with generating certificate with lets encrypt certbot certonly -d mydomain.com
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/vaultwarden#583