element-hq / element-hq/dendrite

create-account not working when password longer then 72 bytes

Open
#3,012 14 comments 0 reactions 0 assignees View on GitHub
T-Defect
Dominant language
Go
Stars
965
Forks
101
PR merge metrics
No merged PRs in 30d

Description

*This issue was originally created by [**@DynamicOperationsArchitect**](https://github.com/DynamicOperationsArchitect) at .*

### Background information
- **Dendrite version or git SHA**: 0.12.0 and 0.11.1
- **SQLite3 or Postgres?**: Postgres
- **Running in Docker?**: no
- **`go version`**: 1.19
- **Client used (if applicable)**: n/a

### Description

- **What** is the problem: create-account does not function. The script runs, asks for a password, says "Created account" but the account does not get created.
- **Who** is affected: The admin
- **How** is this bug manifesting: When running create-account on the command line.
- **When** did this first appear: Last time I successfully created a user was on 0.10.0. Somewhere on the way to 0.11.1 it stopped working.

### Steps to reproduce
- execute './bin/create-account -config ./dendrite.yaml -username new-user'
- check the Postgres tables userapi_profiles and userapi_accounts

### Console output
Create Account:
```
./bin/create-account -config ./dendrite.yaml -username new-user
Enter Password:
Confirm Password:
INFO[0009] Created account: new-user (AccessToken: RemovedForSecurityReasons)
```
Check Postgres tables:
```
dendrite=# select * from userapi_profiles WHERE localpart = 'new-user';
localpart | display_name | avatar_url | server_name
-----------+--------------+------------+-------------
(0 rows)
```
```
dendrite=# select localpart,created_ts from userapi_accounts WHERE localpart = 'new-user';
localpart | created_ts
-----------+------------
(0 rows)
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.