Use Crypto++ RSA::PublicKey to decrypt cipher text
<p>I have the n, d, e for RSA algorithm. However, I want to use private_key to encrypt some string, generate <em>USER_CERTIFICATION</em>, and use public_key for users to decrypt it and get the string. I know if I do so, the string can be easily decrypted by anyone, but security is <strong>not</strong> my concern at all, I just need that <strong>no one except me</strong> can generate the <em>USER_CERTIFICATION</em></p>

<p>I'm using CryptoPP, the code for encoding works fine:</p>

<pre><code>Integer _n(...), _e(...), _d(...);
AutoSeededRandomPool rng;
RSA::PrivateKey k;
k.Initialize(_n, _e, _d);
RSAES_PKCS1v15_Encryptor enc(k);
std::string cipher;
StringSource ss1( plain, true,
    new PK_EncryptorFilter( rng, enc,
        new StringSink( cipher )) // PK_EncryptorFilter
    ); // StringSource
</code></pre>

<p>but the decryption code throws an exception: "class CryptoPP::InvertibleRSAFunction: Missing required parameter 'Prime1'"</p>

<pre><code>Integer _n(...), _e(...);

AutoSeededRandomPool rng;
RSA::PublicKey k;
k.Initialize(_n, _e);
RSAES_PKCS1v15_Decryptor dec(k);
std::string plain;
StringSource ss1( cipher, true,
    new PK_DecryptorFilter( rng, dec,
        new StringSink( plain ))
    ); // StringSource
</code></pre>

<p>Is it possible to do this with CryptoPP?</p>