Index: uspace/lib/crypto/aes.c
===================================================================
--- uspace/lib/crypto/aes.c	(revision 8d2dd7f2d52fbc7693f94b66e451eeff3756d061)
+++ uspace/lib/crypto/aes.c	(revision 3b60ea0ab63232b82cbb39069c74d417545a98e6)
@@ -459,5 +459,5 @@
  *
  */
-int aes_encrypt(uint8_t *key, uint8_t *input, uint8_t *output)
+errno_t aes_encrypt(uint8_t *key, uint8_t *input, uint8_t *output)
 {
 	if ((!key) || (!input))
@@ -511,5 +511,5 @@
  *
  */
-int aes_decrypt(uint8_t *key, uint8_t *input, uint8_t *output)
+errno_t aes_decrypt(uint8_t *key, uint8_t *input, uint8_t *output)
 {
 	if ((!key) || (!input))
Index: uspace/lib/crypto/crypto.c
===================================================================
--- uspace/lib/crypto/crypto.c	(revision 8d2dd7f2d52fbc7693f94b66e451eeff3756d061)
+++ uspace/lib/crypto/crypto.c	(revision 3b60ea0ab63232b82cbb39069c74d417545a98e6)
@@ -194,5 +194,5 @@
  *
  */
-int create_hash(uint8_t *input, size_t input_size, uint8_t *output,
+errno_t create_hash(uint8_t *input, size_t input_size, uint8_t *output,
     hash_func_t hash_sel)
 {
@@ -266,5 +266,5 @@
  *
  */
-int hmac(uint8_t *key, size_t key_size, uint8_t *msg, size_t msg_size, 
+errno_t hmac(uint8_t *key, size_t key_size, uint8_t *msg, size_t msg_size, 
     uint8_t *hash, hash_func_t hash_sel)
 {
@@ -322,5 +322,5 @@
  *
  */
-int pbkdf2(uint8_t *pass, size_t pass_size, uint8_t *salt, size_t salt_size,
+errno_t pbkdf2(uint8_t *pass, size_t pass_size, uint8_t *salt, size_t salt_size,
     uint8_t *hash)
 {
Index: uspace/lib/crypto/crypto.h
===================================================================
--- uspace/lib/crypto/crypto.h	(revision 8d2dd7f2d52fbc7693f94b66e451eeff3756d061)
+++ uspace/lib/crypto/crypto.h	(revision 3b60ea0ab63232b82cbb39069c74d417545a98e6)
@@ -30,4 +30,5 @@
 #define LIBCRYPTO_H
 
+#include <errno.h>
 #include <stddef.h>
 #include <stdint.h>
@@ -50,10 +51,10 @@
 } hash_func_t;
 
-extern int rc4(uint8_t *, size_t, uint8_t *, size_t, size_t, uint8_t *);
-extern int aes_encrypt(uint8_t *, uint8_t *, uint8_t *);
-extern int aes_decrypt(uint8_t *, uint8_t *, uint8_t *);
-extern int create_hash(uint8_t *, size_t, uint8_t *, hash_func_t);
-extern int hmac(uint8_t *, size_t, uint8_t *, size_t, uint8_t *, hash_func_t);
-extern int pbkdf2(uint8_t *, size_t, uint8_t *, size_t, uint8_t *);
+extern errno_t rc4(uint8_t *, size_t, uint8_t *, size_t, size_t, uint8_t *);
+extern errno_t aes_encrypt(uint8_t *, uint8_t *, uint8_t *);
+extern errno_t aes_decrypt(uint8_t *, uint8_t *, uint8_t *);
+extern errno_t create_hash(uint8_t *, size_t, uint8_t *, hash_func_t);
+extern errno_t hmac(uint8_t *, size_t, uint8_t *, size_t, uint8_t *, hash_func_t);
+extern errno_t pbkdf2(uint8_t *, size_t, uint8_t *, size_t, uint8_t *);
 
 extern uint16_t crc16_ibm(uint16_t crc, uint8_t *buf, size_t len);
Index: uspace/lib/crypto/rc4.c
===================================================================
--- uspace/lib/crypto/rc4.c	(revision 8d2dd7f2d52fbc7693f94b66e451eeff3756d061)
+++ uspace/lib/crypto/rc4.c	(revision 3b60ea0ab63232b82cbb39069c74d417545a98e6)
@@ -88,5 +88,5 @@
  *
  */
-int rc4(uint8_t *key, size_t key_size, uint8_t *input, size_t input_size,
+errno_t rc4(uint8_t *key, size_t key_size, uint8_t *input, size_t input_size,
     size_t skip, uint8_t *output)
 {
