fn authenticate(&self) -> Result<Self::CookieType, AuthFail> {
        if &self.username == "admin" && hash(&self.password) == "46a8db11f42955c97a9d183a4c1f8c0fcb5b14d4eff9692cfbbee6f566e81e20" {
            Ok(
                AdministratorCookie {
                    userid: 1,
                    username: "administrator".to_string(),
                    display: Some("Administrator".to_string()),
                }
            )
        } else {
            Err(
                AuthFail::new(self.username.to_string(), "Incorrect username".to_string())
            )
        }
    }
/// Authenticate the credentials inside the login form
Authenticate the credentials inside the login form
Authenticate the credentials inside the login form
fn authenticate(&self) -> Result<Self::CookieType, AuthFail> {
        if &self.username == "admin" && hash(&self.password) == "46a8db11f42955c97a9d183a4c1f8c0fcb5b14d4eff9692cfbbee6f566e81e20" {
            Ok(
                AdministratorCookie {
                    userid: 1,
                    username: "administrator".to_string(),
                    display: Some("Administrator".to_string()),
                }
            )
        } else {
            Err(
                AuthFail::new(self.username.to_string(), "Incorrect username".to_string())
            )
        }
    }
fn authenticate ( & self ) -> Result < Self :: CookieType , AuthFail > { if & self . username == " " && hash ( & self . password ) == " " { Ok ( AdministratorCookie { userid : 1 , username : " " . to_string ( ) , display : Some ( " " . to_string ( ) ) , } ) } else { Err ( AuthFail :: new ( self . username . to_string ( ) , " " . to_string ( ) ) ) } }
Authenticate the credentials inside the login form
Authenticate the credentials inside the login form
&self
&self