from Crypto.Cipher import DES # encryption key = b'secretkey' plaintext = b'text to encrypt' cipher = DES.new(key, DES.MODE_ECB) ciphertext = cipher.encrypt(plaintext) # decryption cipher = DES.new(key, DES.MODE_ECB) decryptedtext = cipher.decrypt(ciphertext)In the above example, we have used the `key` as a binary string and `plaintext` as a binary string to be encrypted. The `cipher` is initialized using the `new` method with the `key` and `MODE_ECB` (Electronic Codebook) which is a basic mode of operation for encryption. The `cipher` object then encrypts the `plaintext` to produce `ciphertext`. Similarly, the `cipher` object is used to decrypt the `ciphertext` to obtain the `decryptedtext`. The `Crypto.Cipher` library belongs to the `pycryptodome` package.