decryptAndDecompressFolder: Decrypt and decompress a folder

View source: R/Encryption.R

decryptAndDecompressFolderR Documentation

Decrypt and decompress a folder

Description

Decrypt and decompress a folder

Usage

decryptAndDecompressFolder(sourceFileName, targetFolder, privateKeyFileName)

Arguments

sourceFileName

Name of the file that must be decrypted.

targetFolder

Name of the folder that will hold the unencrypted data.

privateKeyFileName

Name of the file where the private key is stored.

Details

Decrypts the data using the provided private key and extracts all files to a folder.

Examples

## Not run: 
generateKeyPair("public.key", "private.key")

# Create a folder with some data
dir.create("test")
data <- data.frame(x = runif(1000), y = 1:1000)
saveRDS(data, "test/data1.rds")
saveRDS(data, "test/data2.rds")

compressAndEncryptFolder("test", "data.zip.enc", "public.key")
decryptAndDecompressFolder("data.zip.enc", "test2", "private.key")

## End(Not run)


OHDSI/OhdsiSharing documentation built on Sept. 4, 2023, 3:55 p.m.