
C# client RCA/PKCS#1 RSA encrypt method (javascript to c#)
- or -
Post a project like this1779
£250(approx. $336)
- Posted:
- Proposals: 1
- Remote
- #3158782
- OPPORTUNITY
- Awarded
Description
Experience Level: Intermediate
I need a c# .netstandard 2.0 client RCA/PKCS#1 encrypt method that simulates the javascript client version attached.
I have tried the system and bouncy castle solutions but unable to sus out what's going wrong.
Project will be to provide me a client solution or code snippet that performs the following calculations.
No Payment for partial solutions, must provide code that proves the calculation method works as is below
Inputs gives expected output:-
Inputs:-
Exponent="010001"
Modulus="D1E79FF135D14E342D76185C23024E6DEAD4D6EC2C317A526C811E83538EA4E5ED8E1B0EEE5CE26E3C1B6A5F1FE11FA804F28B7E8821CA90AFA5B2F300DF99FDA27C9D2131E031EA11463C47944C05005EF4C1CE932D7F4A87C7563581D9F27F0C305023FCE94997EC7D790696E784357ED803A610EBB71B12A8BE5936429BFD"
MessageToEncrypt="Password1!"
Expected output:
ExpectedResult = "606b7f04373a8ee3d2c35906abebedbf3abde60480a0528329c057a6653f97bc6619cadd893d17b7911b312a908b652ebfa61fa787b1c38fa9b3f39b6cf90607abdf9223fcd745f2712d000f41cad9024f74034849f2e1c3dbb772853553b93278d14eaf1da9b5b50667be516160f884ef0f031f1546c26c29bc4a987634037c"
Javascript client attached that I need c# .netstandard 2.0 version of that takes
the above inputs and generates the expected output.
Should be easy for someone that understands cryptography, javascript and c#.
Javascript entry point: N = modulus above, E = exponent above
// Set the public key fields N and e from hex strings
function RSASetPublic(N,E) {
if(N != null && E != null && N.length > 0 && E.length > 0) {
this.n = parseBigInt(N,16);
this.e = parseInt(E,16);
}else{
alert("Invalid RSA public key");
}
}
Then
// Return the PKCS#1 RSA encryption of "text" as an even-length hex string
function RSAEncrypt(text) {
and using
}else { // am3
BigInteger.prototype.am = am3;
dbits = 28;
}
I have tried the system and bouncy castle solutions but unable to sus out what's going wrong.
Project will be to provide me a client solution or code snippet that performs the following calculations.
No Payment for partial solutions, must provide code that proves the calculation method works as is below
Inputs gives expected output:-
Inputs:-
Exponent="010001"
Modulus="D1E79FF135D14E342D76185C23024E6DEAD4D6EC2C317A526C811E83538EA4E5ED8E1B0EEE5CE26E3C1B6A5F1FE11FA804F28B7E8821CA90AFA5B2F300DF99FDA27C9D2131E031EA11463C47944C05005EF4C1CE932D7F4A87C7563581D9F27F0C305023FCE94997EC7D790696E784357ED803A610EBB71B12A8BE5936429BFD"
MessageToEncrypt="Password1!"
Expected output:
ExpectedResult = "606b7f04373a8ee3d2c35906abebedbf3abde60480a0528329c057a6653f97bc6619cadd893d17b7911b312a908b652ebfa61fa787b1c38fa9b3f39b6cf90607abdf9223fcd745f2712d000f41cad9024f74034849f2e1c3dbb772853553b93278d14eaf1da9b5b50667be516160f884ef0f031f1546c26c29bc4a987634037c"
Javascript client attached that I need c# .netstandard 2.0 version of that takes
the above inputs and generates the expected output.
Should be easy for someone that understands cryptography, javascript and c#.
Javascript entry point: N = modulus above, E = exponent above
// Set the public key fields N and e from hex strings
function RSASetPublic(N,E) {
if(N != null && E != null && N.length > 0 && E.length > 0) {
this.n = parseBigInt(N,16);
this.e = parseInt(E,16);
}else{
alert("Invalid RSA public key");
}
}
Then
// Return the PKCS#1 RSA encryption of "text" as an even-length hex string
function RSAEncrypt(text) {
and using
}else { // am3
BigInteger.prototype.am = am3;
dbits = 28;
}
Stuart G.
100% (5)Projects Completed
5
Freelancers worked with
5
Projects awarded
86%
Last project
16 Feb 2021
United Kingdom
New Proposal
Login to your account and send a proposal now to get this project.
Log inClarification Board Ask a Question
-
There are no clarification messages.
We collect cookies to enable the proper functioning and security of our website, and to enhance your experience. By clicking on 'Accept All Cookies', you consent to the use of these cookies. You can change your 'Cookies Settings' at any time. For more information, please read ourCookie Policy
Cookie Settings
Accept All Cookies