| 570 | } |
| 571 | |
| 572 | void cRSA::SetEncrypting(const cRSAPublicKey* pKey) |
| 573 | { |
| 574 | ASSERT(pKey->mpData->mKeyLength == mpData->mKeyBits); |
| 575 | if (pKey->mpData->mKeyLength != mpData->mKeyBits) |
| 576 | ThrowAndAssert(eInternal(_T("RSA Key length mismatch."))); |
| 577 | |
| 578 | |
| 579 | mpData->mAction = cRSA_i::ENCRYPT; |
| 580 | mpData->mpPublicKey = pKey; |
| 581 | mpData->mpPrivateKey = 0; |
| 582 | } |
| 583 | |
| 584 | void cRSA::SetDecrypting(const cRSAPrivateKey* pKey) |
| 585 | { |
no outgoing calls