File encryption API using AES