Efficient, Flexible And Secure Implementations For Lattice-Based Cryptography.