Adding existing user to Organization fails #179

Closed
opened 2025-11-07 06:27:05 -06:00 by GiteaMirror · 24 comments
Owner

Originally created by @dirtycajunrice on GitHub (Jan 7, 2019).

When adding an existing user to an organization, the email sends properly, but the link fails with "please ask admin to send another invite". When resending the invite, the logging states there is no invite. So its a circular failure :/
Relevant logging:

[2019-01-07 04:54:27][rocket::rocket][INFO] POST /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users/invite application/json; charset=utf-8:
[2019-01-07 04:54:27][_][INFO] Matched: POST /api/organizations/<org_id>/users/invite (send_invite)
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] connecting to 10.0.10.109:25
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 220 <REDACTED> ESMTP Postfix (Ubuntu)<CRLF>
[2019-01-07 04:54:27][lettre::smtp][INFO] connection established to 10.0.10.109:25
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: EHLO bitwarden<CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250-<REDACTED><CRLF>250-PIPELINING<CRLF>250-SIZE 10240000<CRLF>250-VRFY<CRLF>250-ETRN<CRLF>250-STARTTLS<CRLF>250-ENHANCEDSTATUSCODES<CRLF>250-8BITMIME<CRLF>250-DSN<CRLF>250 SMTPUTF8<CRLF>
[2019-01-07 04:54:27][lettre::smtp][DEBUG] server <REDACTED> with {EightBitMime, SmtpUtfEight, StartTls}
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: MAIL FROM:<no-reply@cajun.pro> BODY=8BITMIME SMTPUTF8<CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250 2.1.0 Ok<CRLF>
[2019-01-07 04:54:27][lettre::smtp][INFO] bfcc199b-e80f-435e-96a2-e09d2c2913f4: from=<no-reply@cajun.pro>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: RCPT TO:<<REDACTED>r@gmail.com><CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250 2.1.5 Ok<CRLF>
[2019-01-07 04:54:27][lettre::smtp][INFO] bfcc199b-e80f-435e-96a2-e09d2c2913f4: to=<<REDACTED>r@gmail.com>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: DATA<CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 354 End data with <CR><LF>.<CR><LF><CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: Subject: Join St. Germain Family<CRLF>Content-Type: text/html<CRLF>To: <<REDACTED>r@gmail.com><CRLF>From: "Bitwarden-rs" <no-reply@cajun.pro><CRLF>Date: Mon, 07 Jan 2019 04:54:27 -0000<CRLF>MIME-Version: 1.0<CRLF>Message-ID: <bfcc199b-e80f-435e-96a2-e09d2c2913f4.lettre@localhost><CRLF><CRLF><html>
             <p>You have been invited to join the <b>St. Germain Family</b> organization.<br><br>
             <a href="https://<REDACTED>/#/accept-organization/?organizationId=4<REDACTED>cdd&organizationUserId=<REDACTED>a38fd&email=<REDACTED>r@gmail.com&organizationName=St. Germain Family&token=<REDACTED>">Click here to join</a></p>
             <p>If you do not wish to join this organization, you can safely ignore this email.</p>
             </html><CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: <CRLF>.<CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250 2.0.0 Ok: queued as E3EDAC02E4<CRLF>
[2019-01-07 04:54:27][lettre::smtp][INFO] <REDACTED>d2c2913f4: conn_use=1, status=sent (2.0.0 Ok: queued as E3EDAC02E4)
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: QUIT<CRLF>
[2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 221 2.0.0 Bye<CRLF>
[2019-01-07 04:54:27][_][INFO] Outcome: Success
[2019-01-07 04:54:27][_][INFO] Response succeeded.
[2019-01-07 04:54:27][rocket::rocket][INFO] GET /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users application/json:
[2019-01-07 04:54:27][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users)
[2019-01-07 04:54:27][_][INFO] Outcome: Success
[2019-01-07 04:54:27][_][INFO] Response succeeded.
[2019-01-07 04:54:27][rocket::rocket][INFO] GET /undefined:
[2019-01-07 04:54:27][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-07 04:54:27][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }.
[2019-01-07 04:54:27][_][INFO] Outcome: Failure
[2019-01-07 04:54:27][_][WARN] Responding with 500 Internal Server Error catcher.
[2019-01-07 04:54:27][_][INFO] Response succeeded.
[2019-01-07 04:54:56][rocket::rocket][INFO] POST /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users/8cddcfa5-ad72-4114-819e-58b5e08a38fd/accept application/json; charset=utf-8:
[2019-01-07 04:54:56][_][INFO] Matched: POST /api/organizations/<_org_id>/users/<_org_user_id>/accept (accept_invite)
[2019-01-07 04:54:56][bitwarden_rs::error][ERROR] Error decoding invite JWT.
[CAUSE] Error(
    Base64(
        InvalidByte(
            322,
            32
        )
    )
)
[2019-01-07 04:54:56][_][INFO] Outcome: Success
[2019-01-07 04:54:56][_][INFO] Response succeeded.
[2019-01-07 04:54:56][rocket::rocket][INFO] GET /api/accounts/revision-date application/json:
[2019-01-07 04:54:56][_][INFO] Matched: GET /api/accounts/revision-date (revision_date)
[2019-01-07 04:54:56][rocket::rocket][INFO] GET /undefined image/png:
[2019-01-07 04:54:56][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-07 04:54:56][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }.
[2019-01-07 04:54:56][_][INFO] Outcome: Success
[2019-01-07 04:54:56][_][INFO] Outcome: Failure
[2019-01-07 04:54:56][_][WARN] Responding with 500 Internal Server Error catcher.
[2019-01-07 04:54:56][_][INFO] Response succeeded.
[2019-01-07 04:54:56][_][INFO] Response succeeded.
[2019-01-07 04:54:56][rocket::rocket][INFO] GET /api/sync?excludeDomains=true application/json:
[2019-01-07 04:54:56][_][INFO] Matched: GET /api/sync?<data..> (sync)
[2019-01-07 04:54:56][_][INFO] Outcome: Success
[2019-01-07 04:54:56][_][INFO] Response succeeded.
[2019-01-07 04:54:56][rocket::rocket][INFO] GET /icons/<REDACTED>/icon.png image/png:
[2019-01-07 04:54:56][_][INFO] Matched: GET /icons/<domain>/icon.png (icon)
[2019-01-07 04:54:56][rocket::rocket][INFO] GET /icons/<REDACTED>/icon.png image/png:
[2019-01-07 04:54:56][_][INFO] Matched: GET /icons/<domain>/icon.png (icon)
[2019-01-07 04:54:56][_][INFO] Outcome: Success
[2019-01-07 04:54:56][_][INFO] Outcome: Success
[2019-01-07 04:54:56][_][INFO] Response succeeded.
[2019-01-07 04:54:56][_][INFO] Response succeeded.
[2019-01-07 04:55:38][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8:
[2019-01-07 04:55:38][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate)
[2019-01-07 04:55:38][_][INFO] Outcome: Success
[2019-01-07 04:55:38][_][INFO] Response succeeded.
[2019-01-07 04:55:43][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8:
[2019-01-07 04:55:43][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate)
[2019-01-07 04:55:43][_][INFO] Outcome: Success
[2019-01-07 04:55:43][_][INFO] Response succeeded.
[2019-01-07 04:57:41][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8:
[2019-01-07 04:57:41][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate)
[2019-01-07 04:57:41][_][INFO] Outcome: Success
[2019-01-07 04:57:41][_][INFO] Response succeeded.
[2019-01-07 04:57:43][rocket::rocket][INFO] POST /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users/8cddcfa5-ad72-4114-819e-58b5e08a38fd/reinvite:
[2019-01-07 04:57:43][_][INFO] Matched: POST /api/organizations/<org_id>/users/<user_org>/reinvite (reinvite_user)
[2019-01-07 04:57:43][bitwarden_rs::error][ERROR] No invitation found for user to resend. Try inviting them first.. No invitation found for user to resend. Try inviting them first.
[2019-01-07 04:57:43][_][INFO] Outcome: Success
[2019-01-07 04:57:43][_][INFO] Response succeeded.
[2019-01-07 04:57:45][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8:
[2019-01-07 04:57:45][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate)
[2019-01-07 04:57:45][_][INFO] Outcome: Success
[2019-01-07 04:57:45][_][INFO] Response succeeded.

That has the send, the try, and the resend

Originally created by @dirtycajunrice on GitHub (Jan 7, 2019). When adding an existing user to an organization, the email sends properly, but the link fails with "please ask admin to send another invite". When resending the invite, the logging states there is no invite. So its a circular failure :/ Relevant logging: ``` [2019-01-07 04:54:27][rocket::rocket][INFO] POST /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users/invite application/json; charset=utf-8: [2019-01-07 04:54:27][_][INFO] Matched: POST /api/organizations/<org_id>/users/invite (send_invite) [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] connecting to 10.0.10.109:25 [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 220 <REDACTED> ESMTP Postfix (Ubuntu)<CRLF> [2019-01-07 04:54:27][lettre::smtp][INFO] connection established to 10.0.10.109:25 [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: EHLO bitwarden<CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250-<REDACTED><CRLF>250-PIPELINING<CRLF>250-SIZE 10240000<CRLF>250-VRFY<CRLF>250-ETRN<CRLF>250-STARTTLS<CRLF>250-ENHANCEDSTATUSCODES<CRLF>250-8BITMIME<CRLF>250-DSN<CRLF>250 SMTPUTF8<CRLF> [2019-01-07 04:54:27][lettre::smtp][DEBUG] server <REDACTED> with {EightBitMime, SmtpUtfEight, StartTls} [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: MAIL FROM:<no-reply@cajun.pro> BODY=8BITMIME SMTPUTF8<CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250 2.1.0 Ok<CRLF> [2019-01-07 04:54:27][lettre::smtp][INFO] bfcc199b-e80f-435e-96a2-e09d2c2913f4: from=<no-reply@cajun.pro> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: RCPT TO:<<REDACTED>r@gmail.com><CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250 2.1.5 Ok<CRLF> [2019-01-07 04:54:27][lettre::smtp][INFO] bfcc199b-e80f-435e-96a2-e09d2c2913f4: to=<<REDACTED>r@gmail.com> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: DATA<CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 354 End data with <CR><LF>.<CR><LF><CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: Subject: Join St. Germain Family<CRLF>Content-Type: text/html<CRLF>To: <<REDACTED>r@gmail.com><CRLF>From: "Bitwarden-rs" <no-reply@cajun.pro><CRLF>Date: Mon, 07 Jan 2019 04:54:27 -0000<CRLF>MIME-Version: 1.0<CRLF>Message-ID: <bfcc199b-e80f-435e-96a2-e09d2c2913f4.lettre@localhost><CRLF><CRLF><html> <p>You have been invited to join the <b>St. Germain Family</b> organization.<br><br> <a href="https://<REDACTED>/#/accept-organization/?organizationId=4<REDACTED>cdd&organizationUserId=<REDACTED>a38fd&email=<REDACTED>r@gmail.com&organizationName=St. Germain Family&token=<REDACTED>">Click here to join</a></p> <p>If you do not wish to join this organization, you can safely ignore this email.</p> </html><CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: <CRLF>.<CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 250 2.0.0 Ok: queued as E3EDAC02E4<CRLF> [2019-01-07 04:54:27][lettre::smtp][INFO] <REDACTED>d2c2913f4: conn_use=1, status=sent (2.0.0 Ok: queued as E3EDAC02E4) [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Wrote: QUIT<CRLF> [2019-01-07 04:54:27][lettre::smtp::client][DEBUG] Read: 221 2.0.0 Bye<CRLF> [2019-01-07 04:54:27][_][INFO] Outcome: Success [2019-01-07 04:54:27][_][INFO] Response succeeded. [2019-01-07 04:54:27][rocket::rocket][INFO] GET /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users application/json: [2019-01-07 04:54:27][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users) [2019-01-07 04:54:27][_][INFO] Outcome: Success [2019-01-07 04:54:27][_][INFO] Response succeeded. [2019-01-07 04:54:27][rocket::rocket][INFO] GET /undefined: [2019-01-07 04:54:27][_][INFO] Matched: GET /<p..> (web_files) [2019-01-07 04:54:27][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }. [2019-01-07 04:54:27][_][INFO] Outcome: Failure [2019-01-07 04:54:27][_][WARN] Responding with 500 Internal Server Error catcher. [2019-01-07 04:54:27][_][INFO] Response succeeded. [2019-01-07 04:54:56][rocket::rocket][INFO] POST /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users/8cddcfa5-ad72-4114-819e-58b5e08a38fd/accept application/json; charset=utf-8: [2019-01-07 04:54:56][_][INFO] Matched: POST /api/organizations/<_org_id>/users/<_org_user_id>/accept (accept_invite) [2019-01-07 04:54:56][bitwarden_rs::error][ERROR] Error decoding invite JWT. [CAUSE] Error( Base64( InvalidByte( 322, 32 ) ) ) [2019-01-07 04:54:56][_][INFO] Outcome: Success [2019-01-07 04:54:56][_][INFO] Response succeeded. [2019-01-07 04:54:56][rocket::rocket][INFO] GET /api/accounts/revision-date application/json: [2019-01-07 04:54:56][_][INFO] Matched: GET /api/accounts/revision-date (revision_date) [2019-01-07 04:54:56][rocket::rocket][INFO] GET /undefined image/png: [2019-01-07 04:54:56][_][INFO] Matched: GET /<p..> (web_files) [2019-01-07 04:54:56][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }. [2019-01-07 04:54:56][_][INFO] Outcome: Success [2019-01-07 04:54:56][_][INFO] Outcome: Failure [2019-01-07 04:54:56][_][WARN] Responding with 500 Internal Server Error catcher. [2019-01-07 04:54:56][_][INFO] Response succeeded. [2019-01-07 04:54:56][_][INFO] Response succeeded. [2019-01-07 04:54:56][rocket::rocket][INFO] GET /api/sync?excludeDomains=true application/json: [2019-01-07 04:54:56][_][INFO] Matched: GET /api/sync?<data..> (sync) [2019-01-07 04:54:56][_][INFO] Outcome: Success [2019-01-07 04:54:56][_][INFO] Response succeeded. [2019-01-07 04:54:56][rocket::rocket][INFO] GET /icons/<REDACTED>/icon.png image/png: [2019-01-07 04:54:56][_][INFO] Matched: GET /icons/<domain>/icon.png (icon) [2019-01-07 04:54:56][rocket::rocket][INFO] GET /icons/<REDACTED>/icon.png image/png: [2019-01-07 04:54:56][_][INFO] Matched: GET /icons/<domain>/icon.png (icon) [2019-01-07 04:54:56][_][INFO] Outcome: Success [2019-01-07 04:54:56][_][INFO] Outcome: Success [2019-01-07 04:54:56][_][INFO] Response succeeded. [2019-01-07 04:54:56][_][INFO] Response succeeded. [2019-01-07 04:55:38][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8: [2019-01-07 04:55:38][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate) [2019-01-07 04:55:38][_][INFO] Outcome: Success [2019-01-07 04:55:38][_][INFO] Response succeeded. [2019-01-07 04:55:43][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8: [2019-01-07 04:55:43][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate) [2019-01-07 04:55:43][_][INFO] Outcome: Success [2019-01-07 04:55:43][_][INFO] Response succeeded. [2019-01-07 04:57:41][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8: [2019-01-07 04:57:41][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate) [2019-01-07 04:57:41][_][INFO] Outcome: Success [2019-01-07 04:57:41][_][INFO] Response succeeded. [2019-01-07 04:57:43][rocket::rocket][INFO] POST /api/organizations/459b1158-f272-41d4-bef0-8520f513fcdd/users/8cddcfa5-ad72-4114-819e-58b5e08a38fd/reinvite: [2019-01-07 04:57:43][_][INFO] Matched: POST /api/organizations/<org_id>/users/<user_org>/reinvite (reinvite_user) [2019-01-07 04:57:43][bitwarden_rs::error][ERROR] No invitation found for user to resend. Try inviting them first.. No invitation found for user to resend. Try inviting them first. [2019-01-07 04:57:43][_][INFO] Outcome: Success [2019-01-07 04:57:43][_][INFO] Response succeeded. [2019-01-07 04:57:45][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8: [2019-01-07 04:57:45][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate) [2019-01-07 04:57:45][_][INFO] Outcome: Success [2019-01-07 04:57:45][_][INFO] Response succeeded. ``` That has the send, the try, and the resend
GiteaMirror added the bug label 2025-11-07 06:27:05 -06:00
Author
Owner

@njfox commented on GitHub (Jan 7, 2019):

The logs indicate that the invite token is invalid for some reason, although I just tried and was not able to reproduce this. Does the user belong to any other organizations or were they invited originally from the /admin page?

Also we've found the issue that is preventing you from reinviting the user and will try to fix that today.

@njfox commented on GitHub (Jan 7, 2019): The logs indicate that the invite token is invalid for some reason, although I just tried and was not able to reproduce this. Does the user belong to any other organizations or were they invited originally from the /admin page? Also we've found the issue that is preventing you from reinviting the user and will try to fix that today.
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

They were originally added with /admin + env for disallowing signups. They are a brand new (as of the log) 5 minute old account. Do either of the above cause the issue? Also, wonderful. I love an active project!

@dirtycajunrice commented on GitHub (Jan 7, 2019): They were originally added with /admin + env for disallowing signups. They are a brand new (as of the log) 5 minute old account. Do either of the above cause the issue? Also, wonderful. I love an active project!
Author
Owner

@dani-garcia commented on GitHub (Jan 7, 2019):

The resend bug should be fixed just now in 21b85b78. Having brand new users shoudn't affect anything, I don't think, but I'll try to test it.

@dani-garcia commented on GitHub (Jan 7, 2019): The resend bug should be fixed just now in 21b85b78. Having brand new users shoudn't affect anything, I don't think, but I'll try to test it.
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

Awesome. let me know what happens with the test. I can test the new push, but to make sure im pulling changes, does the master branch immediately update the automatic build for mprasil/bitwarden? (i ask because the commit is only 2 hours old but the last build is 3+ hours old)

@dirtycajunrice commented on GitHub (Jan 7, 2019): Awesome. let me know what happens with the test. I can test the new push, but to make sure im pulling changes, does the master branch immediately update the automatic build for mprasil/bitwarden? (i ask because the commit is only 2 hours old but the last build is 3+ hours old)
Author
Owner

@dani-garcia commented on GitHub (Jan 7, 2019):

No, those builds are triggered manually by @mprasil, and it'll take about an hour after he does that for them to build.

@dani-garcia commented on GitHub (Jan 7, 2019): No, those builds are triggered manually by @mprasil, and it'll take about an hour after he does that for them to build.
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

So i did further testing, and trying to create a user directly from the org without them existing already creates the same error!

[2019-01-07 16:12:59][rocket::rocket][INFO] GET /undefined:
[2019-01-07 16:12:59][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-07 16:12:59][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }.
[2019-01-07 16:12:59][_][INFO] Outcome: Failure
[2019-01-07 16:12:59][_][WARN] Responding with 500 Internal Server Error catcher.
[2019-01-07 16:12:59][_][INFO] Response succeeded.
[2019-01-07 16:13:37][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8:
[2019-01-07 16:13:37][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate)
[2019-01-07 16:13:37][_][INFO] Outcome: Success
[2019-01-07 16:13:37][_][INFO] Response succeeded.
[2019-01-07 16:13:39][rocket::rocket][INFO] POST /api/accounts/register application/json; charset=utf-8:
[2019-01-07 16:13:39][_][INFO] Matched: POST /api/accounts/register (register)
[2019-01-07 16:13:39][bitwarden_rs::error][ERROR] Error decoding invite JWT.
[CAUSE] Error(
    Base64(
        InvalidByte(
            322,
            13
        )
    )
)
[2019-01-07 16:13:39][_][INFO] Outcome: Success
[2019-01-07 16:13:39][_][INFO] Response succeeded.

I am starting to lean towards the possibility that its having an issue reaching an endpoint through reverse proxy...
nginx config:

server {
    listen 443;
    server_name password.<REDACTED>;
    ssl_certificate /config/keys/cajun.pro/fullchain.pem;
    ssl_certificate_key /config/keys/cajun.pro/privkey.pem;

    ssl on;
    ssl_session_cache  builtin:1000  shared:SSL:10m;
    ssl_protocols  TLSv1 TLSv1.1 TLSv1.2;
    ssl_prefer_server_ciphers on;

    access_log            /config/log/nginx/password.access.log;
    error_log             /config/log/nginx/password.error.log;

    client_max_body_size 25m;

    location / {
        proxy_pass http://bitwarden;
        proxy_connect_timeout 300s;
        proxy_read_timeout 300s;
        proxy_set_header Host $host;
        proxy_set_header X-Forwarded-For $remote_addr;
        proxy_set_header X-Forwarded-Host $remote_addr;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-Proto $scheme;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection $connection_upgrade;
        add_header P3P 'CP="ALL DSP COR PSAa PSDa OUR NOR ONL UNI COM NAV"';
    }
    location /notifications/hub {
      proxy_pass http://bitwarden:3012;
    }

    location /notifications/hub/negotiate {
      proxy_pass http://bitwarden;
    }
}

Bitwarden resolves internally as its a docker network (just for clarity)

Nginx access log for the 500 error call (if relevant):


107.77.222.224 - - [07/Jan/2019:10:13:39 -0600] "POST /api/accounts/register HTTP/2.0" 400 189 "https://password.<REDACTED>/" "Mozilla/5.0 (iPhone; CPU iPhone OS 12_1_2 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/12.0 Mobile/15E148 Safari/604.1"
@dirtycajunrice commented on GitHub (Jan 7, 2019): So i did further testing, and trying to create a user directly from the org without them existing already creates the same error! ``` [2019-01-07 16:12:59][rocket::rocket][INFO] GET /undefined: [2019-01-07 16:12:59][_][INFO] Matched: GET /<p..> (web_files) [2019-01-07 16:12:59][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }. [2019-01-07 16:12:59][_][INFO] Outcome: Failure [2019-01-07 16:12:59][_][WARN] Responding with 500 Internal Server Error catcher. [2019-01-07 16:12:59][_][INFO] Response succeeded. [2019-01-07 16:13:37][rocket::rocket][INFO] POST /notifications/hub/negotiate text/plain; charset=UTF-8: [2019-01-07 16:13:37][_][INFO] Matched: POST /notifications/hub/negotiate (negotiate) [2019-01-07 16:13:37][_][INFO] Outcome: Success [2019-01-07 16:13:37][_][INFO] Response succeeded. [2019-01-07 16:13:39][rocket::rocket][INFO] POST /api/accounts/register application/json; charset=utf-8: [2019-01-07 16:13:39][_][INFO] Matched: POST /api/accounts/register (register) [2019-01-07 16:13:39][bitwarden_rs::error][ERROR] Error decoding invite JWT. [CAUSE] Error( Base64( InvalidByte( 322, 13 ) ) ) [2019-01-07 16:13:39][_][INFO] Outcome: Success [2019-01-07 16:13:39][_][INFO] Response succeeded. ``` I am starting to lean towards the possibility that its having an issue reaching an endpoint through reverse proxy... nginx config: ```nginx server { listen 443; server_name password.<REDACTED>; ssl_certificate /config/keys/cajun.pro/fullchain.pem; ssl_certificate_key /config/keys/cajun.pro/privkey.pem; ssl on; ssl_session_cache builtin:1000 shared:SSL:10m; ssl_protocols TLSv1 TLSv1.1 TLSv1.2; ssl_prefer_server_ciphers on; access_log /config/log/nginx/password.access.log; error_log /config/log/nginx/password.error.log; client_max_body_size 25m; location / { proxy_pass http://bitwarden; proxy_connect_timeout 300s; proxy_read_timeout 300s; proxy_set_header Host $host; proxy_set_header X-Forwarded-For $remote_addr; proxy_set_header X-Forwarded-Host $remote_addr; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; add_header P3P 'CP="ALL DSP COR PSAa PSDa OUR NOR ONL UNI COM NAV"'; } location /notifications/hub { proxy_pass http://bitwarden:3012; } location /notifications/hub/negotiate { proxy_pass http://bitwarden; } } ``` Bitwarden resolves internally as its a docker network (just for clarity) Nginx access log for the 500 error call (if relevant): ```log 107.77.222.224 - - [07/Jan/2019:10:13:39 -0600] "POST /api/accounts/register HTTP/2.0" 400 189 "https://password.<REDACTED>/" "Mozilla/5.0 (iPhone; CPU iPhone OS 12_1_2 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/12.0 Mobile/15E148 Safari/604.1" ```
Author
Owner

@njfox commented on GitHub (Jan 7, 2019):

Just to confirm, do you have the DOMAIN environment variable set to an externally resolving hostname? E.g. -e DOMAIN=https://password.foo.com

@njfox commented on GitHub (Jan 7, 2019): Just to confirm, do you have the `DOMAIN` environment variable set to an externally resolving hostname? E.g. `-e DOMAIN=https://password.foo.com`
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

i do. Relevant docker-compose.yaml snippit:

  bitwarden:
    container_name: bitwarden
    hostname: bitwarden
    image: mprasil/bitwarden:latest
    networks:
      - internal
    volumes:
      - /opt/dockerconfigs/bitwarden:/data
    environment:
      - SMTP_HOST=<REDACTED>.109
      - SMTP_FROM=no-reply@cajun.pro
      - SMTP_SSL=false
      - SIGNUPS_ALLOWED=false
      - DOMAIN=https://password.<REDACTED>
      - ADMIN_TOKEN=nYwj<REDACTED>sGZ
    restart: unless-stopped

and the email wouldnt create the link to the instance properly if domain was set improperly or not at all, correct?

@dirtycajunrice commented on GitHub (Jan 7, 2019): i do. Relevant docker-compose.yaml snippit: ```yaml bitwarden: container_name: bitwarden hostname: bitwarden image: mprasil/bitwarden:latest networks: - internal volumes: - /opt/dockerconfigs/bitwarden:/data environment: - SMTP_HOST=<REDACTED>.109 - SMTP_FROM=no-reply@cajun.pro - SMTP_SSL=false - SIGNUPS_ALLOWED=false - DOMAIN=https://password.<REDACTED> - ADMIN_TOKEN=nYwj<REDACTED>sGZ restart: unless-stopped ``` and the email wouldnt create the link to the instance properly if domain was set improperly or not at all, correct?
Author
Owner

@njfox commented on GitHub (Jan 7, 2019):

Right, it would still generate a link, it would just point to http://localhost:8000 (I think) which would be useless to an external user

@njfox commented on GitHub (Jan 7, 2019): Right, it would still generate a link, it would just point to http://localhost:8000 (I think) which would be useless to an external user
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

Yeah. so after multiple tests with more visibility, it looks like although i can create organizations, i cannot add users regardless of new or otherwise. So organization usage is borked whatsoever. all organization additions end with the same console out of

[2019-01-07 16:49:35][rocket::rocket][INFO] GET /api/organizations/cbd578b2-f477-41c1-a8f2-cf21310be7f1/users application/json:
[2019-01-07 16:49:35][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users)
[2019-01-07 16:49:35][_][INFO] Outcome: Success
[2019-01-07 16:49:35][_][INFO] Response succeeded.
[2019-01-07 16:49:35][rocket::rocket][INFO] GET /undefined:
[2019-01-07 16:49:35][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-07 16:49:35][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }.
[2019-01-07 16:49:35][_][INFO] Outcome: Failure
[2019-01-07 16:49:35][_][WARN] Responding with 500 Internal Server Error catcher.
[2019-01-07 16:49:35][_][INFO] Response succeeded.

and this with the registration using the above link

[2019-01-07 16:24:32][_][INFO] Matched: POST /api/accounts/register (register)
[2019-01-07 16:24:32][bitwarden_rs::error][ERROR] Error decoding invite JWT.
[CAUSE] Error(
    Base64(
        InvalidByte(
            322,
            13
        )
    )
)

That was creating a brand new org "test" and using my test alternate email for addition.

@dirtycajunrice commented on GitHub (Jan 7, 2019): Yeah. so after multiple tests with more visibility, it looks like although i can create organizations, i cannot add users regardless of new or otherwise. So organization usage is borked whatsoever. all organization additions end with the same console out of ``` [2019-01-07 16:49:35][rocket::rocket][INFO] GET /api/organizations/cbd578b2-f477-41c1-a8f2-cf21310be7f1/users application/json: [2019-01-07 16:49:35][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users) [2019-01-07 16:49:35][_][INFO] Outcome: Success [2019-01-07 16:49:35][_][INFO] Response succeeded. [2019-01-07 16:49:35][rocket::rocket][INFO] GET /undefined: [2019-01-07 16:49:35][_][INFO] Matched: GET /<p..> (web_files) [2019-01-07 16:49:35][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }. [2019-01-07 16:49:35][_][INFO] Outcome: Failure [2019-01-07 16:49:35][_][WARN] Responding with 500 Internal Server Error catcher. [2019-01-07 16:49:35][_][INFO] Response succeeded. ``` and this with the registration using the above link ``` [2019-01-07 16:24:32][_][INFO] Matched: POST /api/accounts/register (register) [2019-01-07 16:24:32][bitwarden_rs::error][ERROR] Error decoding invite JWT. [CAUSE] Error( Base64( InvalidByte( 322, 13 ) ) ) ``` That was creating a brand new org "test" and using my test alternate email for addition.
Author
Owner

@njfox commented on GitHub (Jan 7, 2019):

Can you go through the invite/registration flow with the browser dev console open (f12)? You should be able to see the traffic under the Network tab. Once you do that, can you compare the POST to /accounts/register and/or /accept and confirm that the token parameter in the body is exactly the same as the one that shows up in the invite link in the logs? It's a longshot, but I'm curious if the SMTP provider is mangling the token somehow

@njfox commented on GitHub (Jan 7, 2019): Can you go through the invite/registration flow with the browser dev console open (f12)? You should be able to see the traffic under the Network tab. Once you do that, can you compare the POST to `/accounts/register` and/or `/accept` and confirm that the token parameter in the body is exactly the same as the one that shows up in the invite link in the logs? It's a longshot, but I'm curious if the SMTP provider is mangling the token somehow
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

Absolutely!
https://hastebin.com/<redacted>
That includes the invite post, the link, the link get, and the registration post :)

@dirtycajunrice commented on GitHub (Jan 7, 2019): Absolutely! `https://hastebin.com/<redacted>` That includes the invite post, the link, the link get, and the registration post :)
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

AHA! ive found it. In the console, the email sent shows

[2019-01-07 17:35:58][lettre::smtp::client][DEBUG] Wrote: Subject: Join test<CRLF>Content-Type: text/html<CRLF>To: <nicholas.totsch@gmail.com><CRLF>From: "Bitwarden-rs" <no-reply@cajun.pro><CRLF>Date: Mon, 07 Jan 2019 17:35:58 -0000<CRLF>MIME-Version: 1.0<CRLF>Message-ID: <9d8b841c-e990-4f74-8679-ac4b76a22d2f.lettre@localhost><CRLF><CRLF><html>
             <p>You have been invited to join the <b>test</b> organization.<br><br>
             <a href="https://password.<REDACTED>/#/accept-organization/?organizationId=cbd578b2-f477-41c1-a8f2-cf21310be7f1&organizationUserId=855afa22-2822-472c-9395-2f7121aef704&email=nicholas.totsch@gmail.com&organizationName=test&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJuYmYiOjE1NDY4ODI1NTgsImV4cCI6MTU0NzMxNDU1OCwiaXNzIjoiaHR0cHM6Ly9wYXNzd29yZC5jYWp1bi5wcm8iLCJzdWIiOiI0MjZiOWNlMy1kYjMyLTRhN2MtYTQ3Yy1lZGY4Y2Q2YTZlNDciLCJlbWFpbCI6Im5pY2hvbGFzLnRvdHNjaEBnbWFpbC5jb20iLCJvcmdfaWQiOiJjYmQ1NzhiMi1mNDc3LTQxYzEtYThmMi1jZjIxMzEwYmU3ZjEiLCJ1c2VyX29yZ19pZCI6Ijg1NWFmYTIyLTI4MjItNDcyYy05Mzk1LTJmNzEyMWFlZjcwNCIsImludml0ZWRfYnlfZW1haWwiOiJuaWNrQGNhanVuLnBybyJ9.JQ2kTikcNr7L0uOflydjVlkm0eeL2Ly8A6prZKZgYuTIhTslexcWcOtYSa07sG4fOuNVeMzZOVW88-YLl_AVjf-9NZcXWt9WnmeXlErwqlj-xkxeaNpGL_VRqEDvP05vBbiwUpG8ayeRL6-hB43CPM-IKZCCkjIzyBH8vl2YBIyQVVP4AqkW2w-HxshAmB3NCUfBPR1zjnrNnf1et12eb1UKkxhYMT2ZayEnVvjKra6MxBBH8F-BqnkxjPClNvy4IwHaD5l6vjEqEehJ2G-uuYHeOOf04WMVbiwYKTFl3YmGfRUrNEUvBa4JU4CcwLq0Z0ZejGvDNDn2mzIbhWCl6A">Click here to join</a></p>
             <p>If you do not wish to join this organization, you can safely ignore this email.</p>
             </html><CRLF>
[2019-01-07 17:35:58][lettre::smtp::client][DEBUG] Wrote: <CRLF>.<CRLF>

with the token as

eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJuYmYiOjE1NDY4ODI1NTgsImV4cCI6MTU0NzMxNDU1OCwiaXNzIjoiaHR0cHM6Ly9wYXNzd29yZC5jYWp1bi5wcm8iLCJzdWIiOiI0MjZiOWNlMy1kYjMyLTRhN2MtYTQ3Yy1lZGY4Y2Q2YTZlNDciLCJlbWFpbCI6Im5pY2hvbGFzLnRvdHNjaEBnbWFpbC5jb20iLCJvcmdfaWQiOiJjYmQ1NzhiMi1mNDc3LTQxYzEtYThmMi1jZjIxMzEwYmU3ZjEiLCJ1c2VyX29yZ19pZCI6Ijg1NWFmYTIyLTI4MjItNDcyYy05Mzk1LTJmNzEyMWFlZjcwNCIsImludml0ZWRfYnlfZW1haWwiOiJuaWNrQGNhanVuLnBybyJ9.JQ2kTikcNr7L0uOflydjVlkm0eeL2Ly8A6prZKZgYuTIhTslexcWcOtYSa07sG4fOuNVeMzZOVW88-YLl_AVjf-9NZcXWt9WnmeXlErwqlj-xkxeaNpGL_VRqEDvP05vBbiwUpG8ayeRL6-hB43CPM-IKZCCkjIzyBH8vl2YBIyQVVP4AqkW2w-HxshAmB3NCUfBPR1zjnrNnf1et12eb1UKkxhYMT2ZayEnVvjKra6MxBBH8F-BqnkxjPClNvy4IwHaD5l6vjEqEehJ2G-uuYHeOOf04WMVbiwYKTFl3YmGfRUrNEUvBa4JU4CcwLq0Z0ZejGvDNDn2mzIbhWCl6A

Yet the link recieved in the email is:

https://password.<REDACTED>/#/accept-organization/?organizationId=cbd578b2-f477-41c1-a8f2-cf21310be7f1&organizationUserId=855afa22-2822-472c-9395-2f7121aef704&email=nicholas.totsch@gmail.com&organizationName=test&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJuYmYiOjE1NDY4ODI1NTgsImV4cCI6MTU0NzMxNDU1OCwiaXNzIjoiaHR0cHM6Ly9wYXNzd29yZC5jYWp1bi5wcm8iLCJzdWIiOiI0MjZiOWNlMy1kYjMyLTRhN2MtYTQ3Yy1lZGY4Y2Q2YTZlNDciLCJlbWFpbCI6Im5pY2hvbGFzLnRvdHNjaEBnbWFpbC5jb20iLCJvcmdfaWQiOiJjYmQ1NzhiMi1mNDc3LTQxYzEtYThmMi1jZjIxMzEwYmU3ZjEiLCJ1c2VyX29yZ19pZCI6Ijg1NWFmYTIyLTI4MjItNDcyYy05Mzk1LTJmNzEyMWFlZjcwNCIsImludml0ZWRfYnlfZW1haWwiOiJuaWNrQGNhanVuLnBybyJ9.JQ2kTikcNr7L0uOflydjVlkm0eeL2Ly8A6prZKZgYuTIhTslexcWcOtYSa07sG4fOuNVeMzZOVW88-YLl_AVjf-9NZcXWt9WnmeXlErwqlj-xkxeaNpGL_VRqEDvP05vBbiwUpG8ayeRL6-hB43CPM-IKZCCkjIzyBH8vl2YBIyQVVP4AqkW2w-HxshAmB3NCUfBPR1zjnrNnf1et12eb1UKkxhYMT2ZayEnVvjKra6MxBBH8F-BqnkxjPClNvy4IwHaD5l6vjEqEehJ2G-uuYHeOOf04WMVbiwYKTFl3YmGfRUrNEUvBa4JU4CcwLq0Z0ZejGvDNDn2mzIb%0D%20hWCl6A

The difference is %0D%20 That is injected towards the end. I dont know why that is being injected either. I cant find it happening in the mail server as its already that as its sent

@dirtycajunrice commented on GitHub (Jan 7, 2019): AHA! ive found it. In the console, the email sent shows ``` [2019-01-07 17:35:58][lettre::smtp::client][DEBUG] Wrote: Subject: Join test<CRLF>Content-Type: text/html<CRLF>To: <nicholas.totsch@gmail.com><CRLF>From: "Bitwarden-rs" <no-reply@cajun.pro><CRLF>Date: Mon, 07 Jan 2019 17:35:58 -0000<CRLF>MIME-Version: 1.0<CRLF>Message-ID: <9d8b841c-e990-4f74-8679-ac4b76a22d2f.lettre@localhost><CRLF><CRLF><html> <p>You have been invited to join the <b>test</b> organization.<br><br> <a href="https://password.<REDACTED>/#/accept-organization/?organizationId=cbd578b2-f477-41c1-a8f2-cf21310be7f1&organizationUserId=855afa22-2822-472c-9395-2f7121aef704&email=nicholas.totsch@gmail.com&organizationName=test&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJuYmYiOjE1NDY4ODI1NTgsImV4cCI6MTU0NzMxNDU1OCwiaXNzIjoiaHR0cHM6Ly9wYXNzd29yZC5jYWp1bi5wcm8iLCJzdWIiOiI0MjZiOWNlMy1kYjMyLTRhN2MtYTQ3Yy1lZGY4Y2Q2YTZlNDciLCJlbWFpbCI6Im5pY2hvbGFzLnRvdHNjaEBnbWFpbC5jb20iLCJvcmdfaWQiOiJjYmQ1NzhiMi1mNDc3LTQxYzEtYThmMi1jZjIxMzEwYmU3ZjEiLCJ1c2VyX29yZ19pZCI6Ijg1NWFmYTIyLTI4MjItNDcyYy05Mzk1LTJmNzEyMWFlZjcwNCIsImludml0ZWRfYnlfZW1haWwiOiJuaWNrQGNhanVuLnBybyJ9.JQ2kTikcNr7L0uOflydjVlkm0eeL2Ly8A6prZKZgYuTIhTslexcWcOtYSa07sG4fOuNVeMzZOVW88-YLl_AVjf-9NZcXWt9WnmeXlErwqlj-xkxeaNpGL_VRqEDvP05vBbiwUpG8ayeRL6-hB43CPM-IKZCCkjIzyBH8vl2YBIyQVVP4AqkW2w-HxshAmB3NCUfBPR1zjnrNnf1et12eb1UKkxhYMT2ZayEnVvjKra6MxBBH8F-BqnkxjPClNvy4IwHaD5l6vjEqEehJ2G-uuYHeOOf04WMVbiwYKTFl3YmGfRUrNEUvBa4JU4CcwLq0Z0ZejGvDNDn2mzIbhWCl6A">Click here to join</a></p> <p>If you do not wish to join this organization, you can safely ignore this email.</p> </html><CRLF> [2019-01-07 17:35:58][lettre::smtp::client][DEBUG] Wrote: <CRLF>.<CRLF> ``` with the token as ``` eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJuYmYiOjE1NDY4ODI1NTgsImV4cCI6MTU0NzMxNDU1OCwiaXNzIjoiaHR0cHM6Ly9wYXNzd29yZC5jYWp1bi5wcm8iLCJzdWIiOiI0MjZiOWNlMy1kYjMyLTRhN2MtYTQ3Yy1lZGY4Y2Q2YTZlNDciLCJlbWFpbCI6Im5pY2hvbGFzLnRvdHNjaEBnbWFpbC5jb20iLCJvcmdfaWQiOiJjYmQ1NzhiMi1mNDc3LTQxYzEtYThmMi1jZjIxMzEwYmU3ZjEiLCJ1c2VyX29yZ19pZCI6Ijg1NWFmYTIyLTI4MjItNDcyYy05Mzk1LTJmNzEyMWFlZjcwNCIsImludml0ZWRfYnlfZW1haWwiOiJuaWNrQGNhanVuLnBybyJ9.JQ2kTikcNr7L0uOflydjVlkm0eeL2Ly8A6prZKZgYuTIhTslexcWcOtYSa07sG4fOuNVeMzZOVW88-YLl_AVjf-9NZcXWt9WnmeXlErwqlj-xkxeaNpGL_VRqEDvP05vBbiwUpG8ayeRL6-hB43CPM-IKZCCkjIzyBH8vl2YBIyQVVP4AqkW2w-HxshAmB3NCUfBPR1zjnrNnf1et12eb1UKkxhYMT2ZayEnVvjKra6MxBBH8F-BqnkxjPClNvy4IwHaD5l6vjEqEehJ2G-uuYHeOOf04WMVbiwYKTFl3YmGfRUrNEUvBa4JU4CcwLq0Z0ZejGvDNDn2mzIbhWCl6A ``` Yet the link recieved in the email is: ``` https://password.<REDACTED>/#/accept-organization/?organizationId=cbd578b2-f477-41c1-a8f2-cf21310be7f1&organizationUserId=855afa22-2822-472c-9395-2f7121aef704&email=nicholas.totsch@gmail.com&organizationName=test&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJuYmYiOjE1NDY4ODI1NTgsImV4cCI6MTU0NzMxNDU1OCwiaXNzIjoiaHR0cHM6Ly9wYXNzd29yZC5jYWp1bi5wcm8iLCJzdWIiOiI0MjZiOWNlMy1kYjMyLTRhN2MtYTQ3Yy1lZGY4Y2Q2YTZlNDciLCJlbWFpbCI6Im5pY2hvbGFzLnRvdHNjaEBnbWFpbC5jb20iLCJvcmdfaWQiOiJjYmQ1NzhiMi1mNDc3LTQxYzEtYThmMi1jZjIxMzEwYmU3ZjEiLCJ1c2VyX29yZ19pZCI6Ijg1NWFmYTIyLTI4MjItNDcyYy05Mzk1LTJmNzEyMWFlZjcwNCIsImludml0ZWRfYnlfZW1haWwiOiJuaWNrQGNhanVuLnBybyJ9.JQ2kTikcNr7L0uOflydjVlkm0eeL2Ly8A6prZKZgYuTIhTslexcWcOtYSa07sG4fOuNVeMzZOVW88-YLl_AVjf-9NZcXWt9WnmeXlErwqlj-xkxeaNpGL_VRqEDvP05vBbiwUpG8ayeRL6-hB43CPM-IKZCCkjIzyBH8vl2YBIyQVVP4AqkW2w-HxshAmB3NCUfBPR1zjnrNnf1et12eb1UKkxhYMT2ZayEnVvjKra6MxBBH8F-BqnkxjPClNvy4IwHaD5l6vjEqEehJ2G-uuYHeOOf04WMVbiwYKTFl3YmGfRUrNEUvBa4JU4CcwLq0Z0ZejGvDNDn2mzIb%0D%20hWCl6A ``` The difference is `%0D%20` That is injected towards the end. I dont know why that is being injected either. I cant find it happening in the mail server as its already that as its sent
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

Further testing has shown connecting directly to gsuite instead of my postfix proxy does not mangle the link. That objectively defines my proxy as the point of failure. Ill look into that on my side. That just leaves the other thing thats actually a bug!
Update for notation:
Further conversation with the devs and they established that smtp has a max line limitation of 998 characters.
Leaving this open for both bugs <3

@dirtycajunrice commented on GitHub (Jan 7, 2019): ~~Further testing has shown connecting directly to gsuite instead of my postfix proxy does not mangle the link. That objectively defines my proxy as the point of failure. Ill look into that on my side. That just leaves the other thing thats actually a bug!~~ Update for notation: Further conversation with the devs and they established that smtp has a max line limitation of 998 characters. Leaving this open for both bugs <3
Author
Owner

@dani-garcia commented on GitHub (Jan 7, 2019):

I pushed 50eeb4f65, which should remove any strange whitespace added, I tested it adding those characters you mention and it seems to work now. This would make the links work, at least.

@dani-garcia commented on GitHub (Jan 7, 2019): I pushed 50eeb4f65, which should remove any strange whitespace added, I tested it adding those characters you mention and it seems to work now. This would make the links work, at least.
Author
Owner

@dirtycajunrice commented on GitHub (Jan 7, 2019):

Woot! I’ll monitor for the docker build

@dirtycajunrice commented on GitHub (Jan 7, 2019): Woot! I’ll monitor for the docker build
Author
Owner

@mprasil commented on GitHub (Jan 7, 2019):

Just triggered it :) Should be ready in about an hour.

@mprasil commented on GitHub (Jan 7, 2019): Just triggered it :) Should be ready in about an hour.
Author
Owner

@njfox commented on GitHub (Jan 8, 2019):

@DirtyCajunRice have you had a chance to test whether this resolves the issue?

@njfox commented on GitHub (Jan 8, 2019): @DirtyCajunRice have you had a chance to test whether this resolves the issue?
Author
Owner

@dirtycajunrice commented on GitHub (Jan 8, 2019):

Sorry been on a bender with a sql install at work. Testing now

On Mon, Jan 7, 2019 at 9:11 PM Nick Fox notifications@github.com wrote:

@DirtyCajunRice https://github.com/DirtyCajunRice have you had a chance
to test whether this resolves the issue?


You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub
https://github.com/dani-garcia/bitwarden_rs/issues/329#issuecomment-452160185,
or mute the thread
https://github.com/notifications/unsubscribe-auth/APDrWr6lkghuF5RkMLYP9m252aTU3wM0ks5vBAxPgaJpZM4Zy3gK
.

@dirtycajunrice commented on GitHub (Jan 8, 2019): Sorry been on a bender with a sql install at work. Testing now On Mon, Jan 7, 2019 at 9:11 PM Nick Fox <notifications@github.com> wrote: > @DirtyCajunRice <https://github.com/DirtyCajunRice> have you had a chance > to test whether this resolves the issue? > > — > You are receiving this because you were mentioned. > > > Reply to this email directly, view it on GitHub > <https://github.com/dani-garcia/bitwarden_rs/issues/329#issuecomment-452160185>, > or mute the thread > <https://github.com/notifications/unsubscribe-auth/APDrWr6lkghuF5RkMLYP9m252aTU3wM0ks5vBAxPgaJpZM4Zy3gK> > . >
Author
Owner

@dirtycajunrice commented on GitHub (Jan 8, 2019):

As of the docker build from 6 hours ago it is still an issue.

@dirtycajunrice commented on GitHub (Jan 8, 2019): As of the docker build from 6 hours ago it is still an issue.
Author
Owner

@dirtycajunrice commented on GitHub (Jan 8, 2019):

In fact there are more things going oddly than before. Before if i removed the unicode i could use the link. Now it always says "Registration not allowed". I removed signups=false and then no matter what the new account could not be created. That includes deleting and adding the account over

[2019-01-08 04:22:05][rocket::rocket][INFO] GET /api/organizations/43dcbcda-2c31-43df-bfd3-b35aef801aef/users application/json:
[2019-01-08 04:22:05][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users)
[2019-01-08 04:22:05][_][INFO] Outcome: Success
[2019-01-08 04:22:05][_][INFO] Response succeeded.
[2019-01-08 04:23:38][rocket::rocket][INFO] POST /api/accounts/register application/json; charset=utf-8:
[2019-01-08 04:23:38][_][INFO] Matched: POST /api/accounts/register (register)
[2019-01-08 04:23:38][bitwarden_rs::error][ERROR] Registration not allowed. Registration not allowed
[2019-01-08 04:23:38][_][INFO] Outcome: Success
[2019-01-08 04:23:38][_][INFO] Response succeeded.
2019-01-08 04:25:42][_][INFO] Response succeeded.
[2019-01-08 04:25:42][rocket::rocket][INFO] GET /api/organizations/43dcbcda-2c31-43df-bfd3-b35aef801aef/users application/json:
[2019-01-08 04:25:42][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users)
[2019-01-08 04:25:42][_][INFO] Outcome: Success
[2019-01-08 04:25:42][_][INFO] Response succeeded.
[2019-01-08 04:25:42][rocket::rocket][INFO] GET /undefined:
[2019-01-08 04:25:42][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-08 04:25:42][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }.
[2019-01-08 04:25:42][_][INFO] Outcome: Failure
[2019-01-08 04:25:42][_][WARN] Responding with 500 Internal Server Error catcher.
[2019-01-08 04:25:42][_][INFO] Response succeeded.
[2019-01-08 04:26:02][rocket::rocket][INFO] GET / text/html:
[2019-01-08 04:26:02][_][INFO] Matched: GET / (web_index)
[2019-01-08 04:26:02][_][INFO] Outcome: Success
[2019-01-08 04:26:02][_][INFO] Response succeeded.
[2019-01-08 04:26:02][rocket::rocket][INFO] GET /app/main.14e634d61183d686299a.css text/css:
[2019-01-08 04:26:02][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-08 04:26:02][_][INFO] Outcome: Success
[2019-01-08 04:26:02][rocket::rocket][INFO] GET /app/polyfills.14e634d61183d686299a.js:
[2019-01-08 04:26:02][_][INFO] Matched: GET /<p..> (web_files)
[2019-01-08 04:26:02][_][ERROR] Failed to write response: Os { code: 32, kind: BrokenPipe, message: "Broken pipe" }.
[2019-01-08 04:26:02][_][INFO] Outcome: Success
[2019-01-08 04:26:02][_][INFO] Response succeeded.
[2019-01-08 04:26:28][rocket::rocket][INFO] POST /api/accounts/register application/json; charset=utf-8:
[2019-01-08 04:26:28][_][INFO] Matched: POST /api/accounts/register (register)
[2019-01-08 04:26:28][bitwarden_rs::error][ERROR] Account with this email already exists. Account with this email already exists
[2019-01-08 04:26:28][_][INFO] Outcome: Success
[2019-01-08 04:26:28][_][INFO] Response succeeded.
@dirtycajunrice commented on GitHub (Jan 8, 2019): In fact there are more things going oddly than before. Before if i removed the unicode i could use the link. Now it always says "Registration not allowed". I removed signups=false and then no matter what the new account could not be created. That includes deleting and adding the account over ``` [2019-01-08 04:22:05][rocket::rocket][INFO] GET /api/organizations/43dcbcda-2c31-43df-bfd3-b35aef801aef/users application/json: [2019-01-08 04:22:05][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users) [2019-01-08 04:22:05][_][INFO] Outcome: Success [2019-01-08 04:22:05][_][INFO] Response succeeded. [2019-01-08 04:23:38][rocket::rocket][INFO] POST /api/accounts/register application/json; charset=utf-8: [2019-01-08 04:23:38][_][INFO] Matched: POST /api/accounts/register (register) [2019-01-08 04:23:38][bitwarden_rs::error][ERROR] Registration not allowed. Registration not allowed [2019-01-08 04:23:38][_][INFO] Outcome: Success [2019-01-08 04:23:38][_][INFO] Response succeeded. ``` ``` 2019-01-08 04:25:42][_][INFO] Response succeeded. [2019-01-08 04:25:42][rocket::rocket][INFO] GET /api/organizations/43dcbcda-2c31-43df-bfd3-b35aef801aef/users application/json: [2019-01-08 04:25:42][_][INFO] Matched: GET /api/organizations/<org_id>/users (get_org_users) [2019-01-08 04:25:42][_][INFO] Outcome: Success [2019-01-08 04:25:42][_][INFO] Response succeeded. [2019-01-08 04:25:42][rocket::rocket][INFO] GET /undefined: [2019-01-08 04:25:42][_][INFO] Matched: GET /<p..> (web_files) [2019-01-08 04:25:42][_][ERROR] Response was a non-`Responder` `Err`: Os { code: 2, kind: NotFound, message: "No such file or directory" }. [2019-01-08 04:25:42][_][INFO] Outcome: Failure [2019-01-08 04:25:42][_][WARN] Responding with 500 Internal Server Error catcher. [2019-01-08 04:25:42][_][INFO] Response succeeded. [2019-01-08 04:26:02][rocket::rocket][INFO] GET / text/html: [2019-01-08 04:26:02][_][INFO] Matched: GET / (web_index) [2019-01-08 04:26:02][_][INFO] Outcome: Success [2019-01-08 04:26:02][_][INFO] Response succeeded. [2019-01-08 04:26:02][rocket::rocket][INFO] GET /app/main.14e634d61183d686299a.css text/css: [2019-01-08 04:26:02][_][INFO] Matched: GET /<p..> (web_files) [2019-01-08 04:26:02][_][INFO] Outcome: Success [2019-01-08 04:26:02][rocket::rocket][INFO] GET /app/polyfills.14e634d61183d686299a.js: [2019-01-08 04:26:02][_][INFO] Matched: GET /<p..> (web_files) [2019-01-08 04:26:02][_][ERROR] Failed to write response: Os { code: 32, kind: BrokenPipe, message: "Broken pipe" }. [2019-01-08 04:26:02][_][INFO] Outcome: Success [2019-01-08 04:26:02][_][INFO] Response succeeded. [2019-01-08 04:26:28][rocket::rocket][INFO] POST /api/accounts/register application/json; charset=utf-8: [2019-01-08 04:26:28][_][INFO] Matched: POST /api/accounts/register (register) [2019-01-08 04:26:28][bitwarden_rs::error][ERROR] Account with this email already exists. Account with this email already exists [2019-01-08 04:26:28][_][INFO] Outcome: Success [2019-01-08 04:26:28][_][INFO] Response succeeded. ```
Author
Owner

@dani-garcia commented on GitHub (Jan 8, 2019):

Did you try deleting the invited account from the admin panel before inviting the user again?

@dani-garcia commented on GitHub (Jan 8, 2019): Did you try deleting the invited account from the admin panel before inviting the user again?
Author
Owner

@dani-garcia commented on GitHub (Jan 8, 2019):

Note that there was an error in the reinvite logic that was just fixed by f1161c65f

@dani-garcia commented on GitHub (Jan 8, 2019): Note that there was an error in the reinvite logic that was just fixed by f1161c65f
Author
Owner

@dani-garcia commented on GitHub (Jan 10, 2019):

This should be fixed now

@dani-garcia commented on GitHub (Jan 10, 2019): This should be fixed now
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vaultwarden#179