[EDIT: please see C# / OPENSSH RSA ENCRYPTION MADE EVEN EASIER]
The struggle to uncover the secrets of importing from and export to OpenSSH keys with Microsoft's .NET RSACryptoServiceProvider is real. It's possible but not practical to do this without BouncyCastle, which may or may not be well-documented (navigating their website is far from a joyful experience), but after trawling the web and playing around I've created the following gists that should be of assistance to anyone who needs to do this in a straightforward manner.
And if you want to share RSA keys between JavaScript and .NET platforms, well, you're going to need to do this.
Import and export RSA Keys between C# and PEM format using BouncyCastle
And just because the actual encryption and decryption are always annoying:
Simple RSA Encryption to and Decryption from Base64 encoded strings in C#
ARCHIVE NOTICE
My website can still be found at industrialcuriosity.com, but I have not been posting on this blog as I've been primarily focused on therightstuff.medium.com - please head over there and take a look!
Wednesday, 4 October 2017
Subscribe to:
Posts (Atom)
Labels
algorithms
(2)
art
(2)
automation
(8)
aws
(4)
azure
(2)
bamboo
(1)
banking
(2)
blockchain
(1)
books
(5)
c#
(7)
cloud
(4)
collaboration
(5)
comics
(3)
comments
(4)
communication
(6)
crypto
(1)
data ownership
(1)
database
(5)
deployment
(10)
design
(3)
design patterns
(2)
development
(32)
devops
(5)
documentation
(16)
dynamodb
(1)
encryption
(6)
formatting
(4)
git
(1)
golang
(1)
google
(1)
hiring
(1)
html5
(5)
iis
(1)
installation
(5)
integration
(2)
interfaces
(2)
java
(1)
javascript
(11)
lambda
(2)
linux
(5)
mysql
(1)
node.js
(7)
open source
(15)
plugins
(3)
privacy
(2)
processes
(2)
promotions
(1)
python
(4)
readability
(3)
recruitment
(1)
regex
(2)
reviews
(1)
security
(13)
self-publishing
(2)
shakespeare
(3)
sql server
(1)
tattoos
(2)
tools
(21)
user experience
(1)
version control
(3)
virtualization
(1)