Skip to content

Instantly share code, notes, and snippets.

View Shahbazsultan's full-sized avatar

Shahbaz sultan Shahbazsultan

  • Spurtree technologies pvt ltd
  • Bengaluru
View GitHub Profile
@Shahbazsultan
Shahbazsultan / MyActivity.java
Created January 24, 2019 17:21
Keystore android encryption and decryption
public class MyActivity extends AppCompatActivity{
@Override
public void onCreate(Bundle savedInstanceState) {
setcontentView(R.layout.myview);
//To set the encrypted string to keystore
SharedPrefUtils.put(MyActivity.this , "My Key" ,"My keys value");
//To get the decrypted string from keystore
@Shahbazsultan
Shahbazsultan / DeCryptor.java
Created January 22, 2019 07:08 — forked from JosiasSena/DeCryptor.java
Encryptor and Decryptor for data encryption.decryption using the Android KeyStore.
/**
_____ _____ _
| __ \ / ____| | |
| | | | ___| | _ __ _ _ _ __ | |_ ___ _ __
| | | |/ _ \ | | '__| | | | '_ \| __/ _ \| '__|
| |__| | __/ |____| | | |_| | |_) | || (_) | |
|_____/ \___|\_____|_| \__, | .__/ \__\___/|_|
__/ | |
|___/|_|
*/