7 releases (stable)

1.2.2 Mar 24, 2023
1.2.1 Mar 8, 2023
1.0.23 Feb 23, 2023
0.1.1 Oct 13, 2022
0.0.1 Oct 13, 2022

#7 in #exists

Download history 5/week @ 2024-02-23 4/week @ 2024-03-01 2/week @ 2024-03-08 2/week @ 2024-03-15 86/week @ 2024-03-29

90 downloads per month

MIT license

155KB
3K SLoC

keyauth rust library

https://docs.rs/keyauth/latest/keyauth/

if you find any bugs. please report them https://github.com/D0A1V2I3D/keyauth-rust/issues

note

a lot of code is from the official keyauth library, now you may ask why does this even exist if it's the same code from the official library? well the official library is old and uses 1.0 api only this has all 3 api versions and also seller api additionaly its on crates.io, so you can just import it in Cargo.toml

TODO

pre obfuscated version using https://docs.rs/goldberg/latest/goldberg/


lib.rs:

unofficial keyauth library that implements all versions of the api. to make an api version available use the feature flag for that version. example

keyauth = { version = "*" } # this will enable 1.2 api version (default)

by default the 1.2 api is enabled because it is most commonly used. so if you dont want the 1.2 api you have to disable it.

keyauth = { version = "*", features = ["v1_1", "seller"], default-features = false } # this will enable 1.1 and seller api

the default-features = false disabled the default v1_2 api.

basic usage:

let mut auth = keyauth::v1_2::KeyauthApi::new("application name", "ownerid", "application secret", "application version", "api url"); // if you dont have a custom domain for api use "https://keyauth.win/api/1.2/"
auth.init(None).unwrap(); // None -> no hash set, Some("hash") -> if you have has checking enabled
auth.login("username".to_string(), "password".to_string(), Some("hwid".to_string())).unwrap(); // if you want to automaticly generate hwid use None insted of Some(...)

also if you want to use an obfuscator for rust i recommend using obfstr and llvm obfuscator

if the panic feature is enabled then the v1_2 api will panic insted of returning an error when it detects that the request was tampered with

Dependencies

~6–21MB
~318K SLoC