From Known-Plaintext Security to Chosen-Plaintext Security