Skip to content
/ JSRP Public

SRP for java, compatible with jsrp(node-srp) and sirp(ruby)

License

Notifications You must be signed in to change notification settings

Taskulu/JSRP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSRP

SRP for java that compatible with jsrp(node-srp) and sirp(ruby)

Only support 4096 Primes with G equals to 5 and use SHA-256 for message digest

Code Example

Login with SRP

String identifier = "username";
String password = "password";

// Create client
Client mClient = new Client(identifier,password);

// Get A
String A = mClient.getPublicKey();

// Send A to server, server will returns B and salt
// User B and salt for creating M1

String M1 = mClient.getProof(B,salt);

// Send M1 to server to verify your identity

Create Verifier and Salt with SRP

String identifier = "username";
String password = "password";

// Create client
Client mClient = new Client(identifier,password);

// Call createVerifier
Verifier result = mClient.createVerifier();

// Salt
result.getSalt();
// Verifier
result.getVerifier();

Tests

Soon ...

Todo

Implement Server
Write integration test between Client and Server
Add other primes and hash digest

License

MIT License

Copyright (c) 2016 Taskulu

About

SRP for java, compatible with jsrp(node-srp) and sirp(ruby)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages