ddlencemc / rsa-via-openssl-libeay32 Goto Github PK
View Code? Open in Web Editor NEWРеализация шифрования/дешифрование строки алгоритмом RSA через библиотеку openssl на Delphi
Реализация шифрования/дешифрование строки алгоритмом RSA через библиотеку openssl на Delphi
private key (512 bit);
-----BEGIN RSA PRIVATE KEY-----
MIIBOgIBAAJBAMUVTgdp73c0YeU5fItHsNiNINsF6zJjZSCjIvOxBoBrtxzwL2Pe
4IMDjX2m+YShHNdikcIVkB9kIQg6u77z4m8CAwEAAQJBAKmKTFfAYApR+60vqN5A
S/feYFdKXiw4qTRMYrL0pL0vafXdERhnISID2XODy6epQ1N24z9eeRRLVUebIvad
PvECIQDnNFgn+a99ouvKL9dx5jk+Dch+j5efAe5qWry2nI4U3QIhANo4K77GGThi
+xhIcBPJNkfNprjs5rkKxKJd+OZnTGm7AiAM2hkIZ9W8eyD2RUCJoU2PSH7boinA
egABw3d4Ay3WtQIgFLvvlCHYdZ4aA5WmaIreyHXG2J1R0tUuF8tcAfBgt08CIBsS
pR8b4bhxP6rQ2sewzV7cM5PlzwOGFVKrBVXlvPbo
-----END RSA PRIVATE KEY-----
publci key:
-----BEGIN PUBLIC KEY-----
MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAMUVTgdp73c0YeU5fItHsNiNINsF6zJj
ZSCjIvOxBoBrtxzwL2Pe4IMDjX2m+YShHNdikcIVkB9kIQg6u77z4m8CAwEAAQ==
-----END PUBLIC KEY-----
No.1
HudnLQF7vK0g3IBlI/IHDqK6RqGzBqsfeRbh6moxP+k+I6ZVARIxcnXHHMBxQ1oXY/omdknhRAhHWEdrl/D65g==
No.2
tfcd+/WuXwwP9nvO25T6iAORPYqtD0on/HipLciS+7HDdxXxL3KMHdDlUWxKOpXy5PQg6Pwt/cFopxcLBDSf/A==
error:0407006A:rsa routines:RSA_padding_check_PKCS1_type_1:block type is not 01
error:04067072:rsa routines:RSA_EAY_PUBLIC_DECRYPT:padding check failed
//fill last #10
if (re_encode_session[Length(re_encode_session)-1] <> #10) then
begin
re_encode_session:=re_encode_session+ char(10);
end;
//Rsa public decrypt
bRSAData.CryptedData := re_encode_session;
fRSAOpenSSL.PublicDecrypt(bRSAData);
How can crypt decrypt file ?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.