Here's my dilemma. I have a DTS package that gets a list of reports that need to run. It will then iterate through that list via active-X script, and create excel reports. The package then automatically posts them to there individual FTP locations. However, Some of these FTP's are not secure and these clients, as we are dealing with PHI (private health info), have requested that the reports be encrypted via PGP. This is all fine a well except, I can't seem to automate PGP encryption. I am using PGP 9.7.
I know there is a COM object "NSDPGP3Lib" but that only seems to work while being used in VB6 or .NET. I can't get it working in VBS.
Here's what I have for code. Obviously, it's not working yet.
Private Function EncryptFile(FilePath, RcptKeyId)
Set fsObj = CreateObject("Scripting.FileSystemObject")
Set PGP = CreateObject("NSDPGP3Lib.PGP")
Set File = fsObj.GetFile(FilePath)
Public_Ring = "c:\Test.pkr"
Privite_Ring = "c:\Test.skr"
OutputFilePath = Replace(File.Name, ".xls", "")
Call PGP.EncryptFile(Public_Ring, Privite_Ring, FilePath, OutputFilePath, BINARY_FILE, BINARY_FILE, RcptKeyId)
Set PGP = Nothing
Set fsObj = Nothing