View Issue Details

IDProjectCategoryView StatusLast Update
0001549Main CAcert Websiteaccount administrationpublic2023-07-14 16:20
Reporterjandd Assigned Toegal  
PriorityhighSeveritymajorReproducibilityalways
Status fix availableResolutionopen 
PlatformMain CAcert WebsiteOSN/AOS Versionstable
Summary0001549: New user registration fails
DescriptionIt is not possible to register new user accounts. The account registration seems to work first, but after an attempt to register the email address is burned. This is related to 0001543.
Steps To ReproduceAttempt to register a new user with a new email address.
Tagsdatabase
Reviewed by
Test Instructions

Activities

jandd

2023-07-11 16:28

administrator   ~0006167

The issue is caused by missing DEFAULT values on some of the columns in the users table.

jandd

2023-07-11 16:30

administrator   ~0006168

The issue can be fixed by defining DEFAULT values on columns in the users table:

alter table users alter orgadmin set default 0;
alter table users alter adadmin set default 0;
alter table users alter locked set default 0;
alter table users alter otphash set default '';
alter table users alter otppin set default 0;

This will produce the same defaults as the implicit ones in the old MySQL database.

jandd

2023-07-11 16:32

administrator   ~0006169

Last edited: 2023-07-11 16:32

The wrongly create items in the emails table should be removed via:

UPDATE email SET deleted=CURRENT_TIMESTAMP WHERE memid=0;

jandd

2023-07-14 16:20

administrator   ~0006171

I created a pull request with a migration script to add the missing defaults in https://code.cacert.org/cacert/cacert-webdb/pulls/4

Issue History

Date Modified Username Field Change
2023-07-11 16:28 jandd New Issue
2023-07-11 16:28 jandd Assigned To => egal
2023-07-11 16:28 jandd Tag Attached: database
2023-07-11 16:28 jandd Assigned To egal => jandd
2023-07-11 16:28 jandd Status new => needs work
2023-07-11 16:28 jandd Note Added: 0006167
2023-07-11 16:30 jandd Assigned To jandd => egal
2023-07-11 16:30 jandd Status needs work => fix available
2023-07-11 16:30 jandd Note Added: 0006168
2023-07-11 16:32 jandd Note Added: 0006169
2023-07-11 16:32 jandd Note Edited: 0006169
2023-07-14 16:20 jandd Note Added: 0006171