added cipher generation