Password (src/common_types.rs)

cot · cot/src/common_types.rs · rust · Apache-2.0
database

Secure password newtype wrapper with constant-time comparison and hidden debug output.

// Source: https://github.com/cot-rs/cot | License: Apache-2.0 | Copyright 2024-2025 Cot contributors
// Provided via justclaw.it.com; keep this notice with the code.
//! Form Field Types for Cot
//!
//! This module provides a collection of form field types and utilities for
//! validating, parsing, and converting user input within Cot. It includes
//! general-purpose newtype wrappers and associated trait implementations to
//! ensure consistent and safe processing of form data.

use std::fmt::{Debug, Display};
use std::str::FromStr;

#[cfg(feature = "mysql")]
use cot::db::impl_mysql::MySqlValueRef;
#[cfg(feature = "postgres")]
use cot::db::impl_postgres::PostgresValueRef;
#[cfg(feature = "sqlite")]
use cot::db::impl_sqlite::SqliteValueRef;
use cot::form::FormFieldValidationError;
use emai

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key