# Save encryption as XML

**URL:** <https://www.ruby-forum.com/t/save-encryption-as-xml/122248>\
**Category:** Rails\
**Created:** [December 5, 2007, 10:18pm UTC](https://www.ruby-forum.com/t/save-encryption-as-xml/122248 "2007-12-05T22:18:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![snantz](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/c2a13f/32.png) [@snantz](https://www.ruby-forum.com/u/snantz)\
**Post date:** [December 5, 2007, 10:18pm UTC](https://www.ruby-forum.com/t/save-encryption-as-xml/122248/1 "2007-12-05T22:18:43Z")

</div>

I have a strange problem, I have encrypted my cc # using Rails - works  
great, now I need to use that private key to decrypt the # using Visual  
Basic - not working so great. Apparently VB has little or no  
functionality to decrypt something by giving it a private key, unless  
you do it a very weird way, which I am having trouble with. Is there a  
way to get at the modulus and the xponent of the key so I can write it  
as an xml file so VB will be happy? Thanks,

-S
