Commit Graph

5 Commits

Author SHA1 Message Date
graeme thornton
21adb81f48 Created a new interface to RSA functionality that is independent of key size (unlike the old TBigInt version). Internally, RSA functions are implemented by OpenSSL on Windows/Mac/Linux an falling back to the TBigInt implementation for other platforms
- Future plan would be not to use OpenSSL directly, but to go via PlatformCrypto or something like it which could provide platform specific RSA functionality if it exists
- Also contains some compensation code for platforms that are still stuck on an older version of OpenSSL (everything except windows)
- On platforms that use OpenSSL < 1.1.1, register a locking callback so we can provide mutexes and stop it crashing horribly when the same RSA key is used concurrently on different threads

Changed default key size in the CryptoKeys plugin to 4096 bits.

#jira UE-71377
#rb ian.fox, robert.manuszewski, ryan.gerleve

#ROBOMERGE-OWNER: ryan.gerleve
#ROBOMERGE-AUTHOR: graeme.thornton
#ROBOMERGE-SOURCE: CL 5447433 in //UE4/Release-4.22/... via CL 5447485
#ROBOMERGE-BOT: ENGINE (Main -> Dev-Networking)

[CL 5447724 by graeme thornton in Dev-Networking branch]
2019-03-19 09:01:05 -04:00
graeme thornton
a374031f9f Improvements to RSA key generation and pak signing
- CryptoKeys plugin can now be told how many bits to use for keys. Defaults to 2048 as a happy medium between security and performance
- After creating the OpenSSL RSA key, use the exp/mod values directly rather than recomputing from primes
- Added RSA.h with some TBigInt based helpers for RSA keys
- Added FPakSignatureFile to wrap the contents of the pak .sig file, including determining that it is of a new format that supports versioning. Wraps the encryption and decryption of he master table hash
- Changed pak master signature hash from crc to SHA1
- Modified access to executable embedded public key data so that it is just an array of bytes. Will allow custom key sizes in the future.

#rb joe.barrett, stefan.boberg
#jira UE-71280, UE-71377

#ROBOMERGE-OWNER: ryan.gerleve
#ROBOMERGE-AUTHOR: graeme.thornton
#ROBOMERGE-SOURCE: CL 5381335 in //UE4/Release-4.22/... via CL 5383057
#ROBOMERGE-BOT: ENGINE (Main -> Dev-Networking)

[CL 5415560 by graeme thornton in Dev-Networking branch]
2019-03-15 12:02:13 -04:00
graeme thornton
62a6a3af2d Removed signing key generation functionality from unrealpak. Keys should be generated with the CryptoKeys plugin in the editor now
#jira UE-68090


#rb none

#ROBOMERGE-OWNER: ryan.gerleve
#ROBOMERGE-AUTHOR: graeme.thornton
#ROBOMERGE-SOURCE: CL 4760704 via CL 4760706 via CL 4760723
#ROBOMERGE-BOT: ENGINE (Main -> Dev-Networking)

[CL 4760777 by graeme thornton in Dev-Networking branch]
2019-01-21 09:30:11 -05:00
ben marsh
2b46ba7b94 Update copyright notices to 2019.
#rb none
#lockdown Nick.Penwarden

#ROBOMERGE-OWNER: ryan.gerleve
#ROBOMERGE-AUTHOR: ben.marsh
#ROBOMERGE-SOURCE: CL 4662404 in //UE4/Main/...
#ROBOMERGE-BOT: ENGINE (Main -> Dev-Networking)

[CL 4662413 by ben marsh in Dev-Networking branch]
2018-12-14 13:44:01 -05:00
Ryan Gerleve
e7612e89b2 Merging //UE4/Dev-Main to Dev-Networking (//UE4/Dev-Networking)
#rb none
#rnx

[CL 4341874 by Ryan Gerleve in Dev-Networking branch]
2018-09-04 14:32:41 -04:00