{"id":18391565,"url":"https://github.com/fibrefox/password-encoder-for-spring-security-hashes","last_synced_at":"2026-05-01T19:33:43.258Z","repository":{"id":152031320,"uuid":"618088669","full_name":"FibreFoX/password-encoder-for-spring-security-hashes","owner":"FibreFoX","description":"Rust library to handle password hashes managed by common Spring Boot application using Spring Security","archived":false,"fork":false,"pushed_at":"2023-09-02T07:49:14.000Z","size":71,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-06T09:50:34.106Z","etag":null,"topics":["password","rust","rust-library","security","spring","spring-security"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FibreFoX.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-23T18:19:02.000Z","updated_at":"2024-03-22T11:14:40.000Z","dependencies_parsed_at":"2024-11-06T02:02:15.437Z","dependency_job_id":"41c735bc-ebf9-4e4a-9aae-68b50a71b1d7","html_url":"https://github.com/FibreFoX/password-encoder-for-spring-security-hashes","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/FibreFoX/password-encoder-for-spring-security-hashes","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FibreFoX%2Fpassword-encoder-for-spring-security-hashes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FibreFoX%2Fpassword-encoder-for-spring-security-hashes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FibreFoX%2Fpassword-encoder-for-spring-security-hashes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FibreFoX%2Fpassword-encoder-for-spring-security-hashes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FibreFoX","download_url":"https://codeload.github.com/FibreFoX/password-encoder-for-spring-security-hashes/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FibreFoX%2Fpassword-encoder-for-spring-security-hashes/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32510807,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["password","rust","rust-library","security","spring","spring-security"],"created_at":"2024-11-06T01:52:24.656Z","updated_at":"2026-05-01T19:33:43.239Z","avatar_url":"https://github.com/FibreFoX.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Password encoders for Spring Security hashes in Rust\n\nUsing a web server in Rust is easy, simply choose between [Rocket](https://rocket.rs/) or [Actix](https://actix.rs/) (or\nothers). But what about handling password hashes generated\nfrom [Spring Security](https://spring.io/projects/spring-security)? I could not find anything, so this library is meant\nto fill the gap.\n\n**Note/Warning:** This is a learning project (yet)! I'm usually developing with Java, this is an experiment to migrate a\nSpring Boot project to run with Rust built systems.\n\n## Usage\n\nAdd dependency to your `Cargo.toml`:\n\n```toml\n[dependencies]\npassword-encoder-for-spring-security-hashes = \"0.1.0\"\n```\n\nCreating a password hash:\n\n```rust\nuse password_encoder_for_spring_security_hashes::PasswordEncoder;\nuse password_encoder_for_spring_security_hashes::encoder::delegating::DelegatingPasswordEncoder;\n\nfn main() {\n    let encoder: DelegatingPasswordEncoder = Default::default();\n\n    let some_entered_password = String::from(\"SomeSecurePassword\");\n\n    let password_hash_to_store = encoder.encode_spring_security_hash(\u0026some_entered_password);\n}\n```\n\nChecking if password matches:\n\n```rust\nuse password_encoder_for_spring_security_hashes::PasswordEncoder;\nuse password_encoder_for_spring_security_hashes::encoder::delegating::DelegatingPasswordEncoder;\n\nfn main() {\n    let encoder: DelegatingPasswordEncoder = Default::default();\n\n    let some_entered_password = String::from(\"NotVerySecretPassword\");\n    let some_stored_password_hash = String::from(\"{noop}NotVerySecretPassword\");\n\n    if encoder.matches_spring_security_hash(\u0026some_stored_password_hash, \u0026some_stored_password_hash) {\n        println!(\"(insecure) passwords do match\");\n    }\n}\n```\n\n## Supported encoders\n\n| identifier | Spring Security password encoder class                  | matches | encode | delegated | \n|------------|---------------------------------------------------------|:-------:|:------:|:---------:|\n|            | o.s.s.c.password.DelegatingPasswordEncoder              |    ✅    |   ✅    |     -     |\n| argon2     | o.s.s.c.argon2.Argon2PasswordEncoder                    |   ✏️    |   ✏️   |    ✏️     |\n| bcrypt     | o.s.s.c.bcrypt.BCryptPasswordEncoder                    |    ✅    |   ✅    |     ✅     |\n| pbkdf2     | o.s.s.c.password.Pbkdf2PasswordEncoder                  |   ✏️    |   ✏️   |    ✏️     |\n| scrypt     | o.s.s.c.scrypt.SCryptPasswordEncoder                    |   ✏️    |   ✏️   |    ✏️     |\n| ldap       | o.s.s.c.password.LdapShaPasswordEncoder                 |   ✏️    |   ✏️   |    ✏️     |\n| MD4        | o.s.s.c.password.Md4PasswordEncoder                     |    ✅    |   ✏️   |     ✅     |\n| MD5        | o.s.s.c.password.MessageDigestPasswordEncoder (md5)     |    ✅    |   ✏️   |     ✅     |\n| SHA-1      | o.s.s.c.password.MessageDigestPasswordEncoder (sha-1)   |   ✏️    |   ✏️   |    ✏️     |\n| SHA-256    | o.s.s.c.password.MessageDigestPasswordEncoder (sha-256) |   ✏️    |   ✏️   |    ✏️     |\n| noop       | o.s.s.c.password.NoOpPasswordEncoder                    |    ✅    |   ✅    |     ✅     |\n| sha256     | o.s.s.c.password.StandardPasswordEncoder                |   ✏️    |   ✏️   |    ✏️     |\n\n**Note:** there will be no 100% feature matching to the Spring Security implementation, especially custom configuration\nof each encoder is not planned to be implemented.\n\n### Icon legend\n\n✏️: implementation planned / work in progress  \n✅: implemented\n\n## License\n\nApache-2.0\n\n\"Spring\", \"Spring Boot\" and \"Spring Security\" are [trademarks](https://spring.io/trademarks) of Pivotal Software, Inc.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffibrefox%2Fpassword-encoder-for-spring-security-hashes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffibrefox%2Fpassword-encoder-for-spring-security-hashes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffibrefox%2Fpassword-encoder-for-spring-security-hashes/lists"}