title: How to generate a 128 bit key to use in AES algorithm
body: <p>I am using the code in below mentioned post to encrypt and decrypt values between Java and Java script module of my application.</p>
  
  <p><a href="https://stackoverflow.com/questions/23321049/compatible-aes-algorithm-for-java-and-javascript">Compatible AES algorithm for Java and Javascript</a></p>
  
  <p>In a above post they are using 128 bit key value. I want to use my own key instead of hard coding the 128 bit key value.</p>
  
  <p>My question is that can I convert any random string into 128 bit key value.</p>
  
  <p>Please post some examples if it is possible to convert any string into 128 bit value.</p>