code: public static byte[] encrypt(byte[] str, Key encrypting_key, String algorithm) {
  		try {
  			// Initialize the encoder
  			final Cipher cipher = Cipher.getInstance(algorithm);
  			cipher.init(Cipher.ENCRYPT_MODE, encrypting_key);
  
  			// Encode
  			return cipher.doFinal(str);
  		} catch (Exception e) {
  			return null;
  		}
  	}
docs: Encrypt the specified string according to the given key.
  
  <p>Caution: this function use some Sun's JDK classes.
  
  <p>The DES algorithm is used.
  
  @param str is the string to encrypt
  @param encrypting_key is the key used for encryption.
  @param algorithm is the name of the encryption algorithm.
  @return the encryption result or the empty string