# Android Cryptography Kotlin Samples

Android Kotlin cryptography examples including hash calculation, AES encryption/decryption, and Base64 encoding

> Canonical page: https://elysiatools.com/en/samples/android-cryptography-kotlin

- **Category:** Kotlin

- **Keywords:** kotlin, android, cryptography, encryption, hash, security, aes, base64

## Overview

Android Kotlin cryptography examples including hash calculation, AES encryption/decryption, and Base64 encoding

## Examples

- **Hash Calculation**: Calculate MD5, SHA-1, SHA-256, and SHA-512 hashes for strings and files
- **AES Encryption**: Encrypt and decrypt data using AES with various modes and padding schemes
- **Base64 Encoding**: Encode and decode data using Base64 with various options and character sets

## When to use

- Use this sample set when you want reference inputs for Android Cryptography Kotlin Samples.
- Use it to preview output formats and compare related sample variants.

## How it works

- Open a sample entry to inspect the prepared example payload or asset.
- Compare it with related tools to understand how the workflow connects.

## Use cases

- Hash Calculation
- AES Encryption
- Base64 Encoding

## Frequently asked questions

### What is included in Android Cryptography Kotlin Samples?

This page includes curated sample entries, related tools, and neighboring sample collections for Android Cryptography Kotlin Samples.

## Related tools

- [Figma iOS Android pt dp sp Responsive Design Spec Card](https://elysiatools.com/en/tools/figma-ios-android-pt-dp-sp-responsive-design-spec-card): Convert a Figma px value into iOS pt, Android dp/sp, web rem/vw with a fluid clamp() snippet, a density-bucket render table and a touch-target accessibility audit, as a developer spec card.
- [AES Encryption Tool](https://elysiatools.com/en/tools/aes-encryption-tool): Encrypt or decrypt text and files with AES-256-GCM and export IV-based bundles
- [JSON to Kotlin Data Class Converter](https://elysiatools.com/en/tools/json-to-kotlin): Convert JSON data into Kotlin data classes with @SerializedName annotations, nullable handling, and nested type inference
- [Hash Algorithm Comparator](https://elysiatools.com/en/tools/hash-algorithm-comparator): Hash the same input with MD5, SHA-1, SHA-256, SHA-512, BLAKE2b, and BLAKE3 at the same time and compare them side by side: output length, hex/Base64 digest, security status (broken / modern), and a relative speed benchmark. Great for teaching, choosing a hashing algorithm, or sanity-checking checksums.
- [RSA Encrypt / Decrypt](https://elysiatools.com/en/tools/rsa-encrypt-decrypt): Encrypt text with an RSA public key or decrypt ciphertext with the matching private key, using OAEP padding (SHA-1 or SHA-256). Handles long messages by chunking. Keys and data stay local. PKCS#1 v1.5 is intentionally not offered (Node disables it for decryption due to Bleichenbacher attacks).
- [Text Encryptor/Decryptor](https://elysiatools.com/en/tools/text-encryptor-decryptor): Simple text encryption and decryption using various algorithms
- [Hash Generator](https://elysiatools.com/en/tools/hash-generator): Generate hash values (MD5, SHA1, SHA256, SHA512)
- [Secure Random Generator](https://elysiatools.com/en/tools/secure-random-generator): Generate cryptographically secure random key material driven by entropy budget — request N bits of entropy, get hex/base64/base64url output. Also supports custom-alphabet strings via crypto.randomInt (rejection-sampled, no modulo bias). Use this instead of Math.random()-based tools for any secret/key/token.

## Related content

- [Android Cryptography Java Samples](https://elysiatools.com/en/samples/android-cryptography-java): Android Java cryptography examples including hash calculation, AES encryption/decryption, and Base64 encoding
- [macOS Cryptography Objective-C Samples](https://elysiatools.com/en/samples/macos-cryptography-objectivec): macOS Objective-C cryptography examples including hash calculation, symmetric encryption, and Base64 encoding
- [Web Cryptography Go Samples](https://elysiatools.com/en/samples/web-cryptography-go): Web Go cryptography and security examples including hash calculation, symmetric encryption, and Base64 encoding/decoding
- [Windows Cryptography C++ Samples](https://elysiatools.com/en/samples/windows-cryptography-cpp): Windows C++ cryptography examples including hash calculation, AES encryption/decryption, and Base64 encoding/decoding
- [Android Date & Time Kotlin Samples](https://elysiatools.com/en/samples/android-datetime-kotlin): Android Kotlin date and time examples including getting current time, formatting dates, and parsing date strings
- [Android File Operations Kotlin Samples](https://elysiatools.com/en/samples/android-file-operations-kotlin): Android Kotlin file operations examples including text file read/write, file copy/move, directory traversal, and file validation
