[R] Help with decrypting

MacQueen, Don
Mon, 07 Nov 2016 22:47:44 -0000

I have a file containing encrypted contents. The contents can be decrypted
using perl, like this:

open (FILEHANDLE, "/path/to/file")
chomp ($ciphertext = <FILEHANDLE>);


use Crypt::CBC;
$cipher = Crypt::CBC->new( -key    => 'my secret key',
                           -cipher => 'Blowfish'
                          );

$plaintext  = $cipher->decrypt($ciphertext);


(See http://search.cpan.org/~lds/Crypt-CBC-2.33/CBC.pm)

M goal is to have the value of $plaintext in an R object, so, is there an
R equivalent to this decrypt() perl function?

I've found R packages
  bcrypt
  sodium
that appear to have potential, but I don't understand this business well
enough to figure out how to use them, if indeed they can be used, for
this. Help would be much appreciated.

Thanks