• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

How to encrypt a file in coldfusion?

New Here ,
May 23, 2018 May 23, 2018

Copy link to clipboard

Copied

I have the necessity to encrypt an excel file generated by a web application developed by myself with Coldfusion. Currently my organization is using a third party software for accomplish the encryption piece with a PGP tool . My goal is to accomplish the encryption the excel file directly in the web application.

Any suggestion on how to accomplish this?

Thanks

Views

1.0K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 23, 2018 May 23, 2018

Copy link to clipboard

Copied

ColdFusion has EncryptBinary() and DecryptBinary() functions that might do what you need.

HTH,

^ _ ^

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 23, 2018 May 23, 2018

Copy link to clipboard

Copied

I would think that if you mean you want to use the PGP tool, against any file, you would want to consider using the CFEXECUTE tag, which lets you run any process on the server (that you would otherwise run from the command line on the server). It can be tricky to get it to work. See the docs, for sure.

/charlie


/Charlie (troubleshooter, carehart.org)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
May 23, 2018 May 23, 2018

Copy link to clipboard

Copied

There used to be a CFC that handled this: BonCode PGP for ColdFusion , but I believe it is pretty out of date with current libraries.  I'd suggest using a Java lib within CF.  I know there were some Java wrappers for bouncycastle.org that you might want to look at.

-Nic

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Aug 08, 2019 Aug 08, 2019

Copy link to clipboard

Copied

LATEST

Another option is to add the excel file as an attachment to a PDF then password protect the pdf, which basically means encrypting the PDF and its contents.  All of which can be done with CF.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation