Removed 'misssing braces' warning.
Added random key generator function.
Work in progress.