code: def encrypt(s, pk, pk_format=SER_COMPACT, mac_bytes=10, curve=None):
      
      curve = (Curve.by_pk_len(len(pk)) if curve is None
               else Curve.by_name(curve))
      p = curve.pubkey_from_string(pk, pk_format)
      return p.encrypt(s, mac_bytes)
docs: Encrypts `s' for public key `pk'