remove password field

This commit is contained in:
Aaron Po
2026-06-23 01:39:57 -04:00
parent b631c0f5db
commit 6883b05824
4 changed files with 4 additions and 31 deletions

View File

@@ -71,22 +71,6 @@ std::string GenerateDateOfBirth(std::mt19937& rng) {
static_cast<unsigned>(birth_ymd.day()));
}
std::string GenerateRandomPassword(std::mt19937& rng) {
constexpr size_t k_password_length = 32;
constexpr std::string_view k_charset =
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789!@#$%^&"
"*";
std::uniform_int_distribution<size_t> char_dist(0, k_charset.size() - 1);
std::string password;
password.reserve(k_password_length);
for (size_t i = 0; i < k_password_length; ++i) {
password.push_back(k_charset[char_dist(rng)]);
}
return password;
}
} // namespace
void BiergartenPipelineOrchestrator::GenerateUsers(
@@ -128,7 +112,6 @@ void BiergartenPipelineOrchestrator::GenerateUsers(
.user = user,
.email = BuildEmail(sampled_name, used_email_local_parts),
.date_of_birth = GenerateDateOfBirth(rng),
.password = GenerateRandomPassword(rng),
};
} catch (const std::exception& e) {
++skipped_count;

View File

@@ -69,12 +69,6 @@ uint64_t SqliteExportService::ProcessRecord(const UserRecord& user) {
.index = sqlite_export_service_internal::kUserDateOfBirthBindIndex,
.value = user.date_of_birth,
.action = "Failed to bind SQLite user date of birth"});
sqlite_export_service_internal::Bind(
insert_user_stmt_,
sqlite_export_service_internal::BindParam<std::string_view>{
.index = sqlite_export_service_internal::kUserPasswordBindIndex,
.value = user.password,
.action = "Failed to bind SQLite user password"});
sqlite_export_service_internal::StepStatement(
db_handle_, insert_user_stmt_, "Failed to insert SQLite user row");