Sending Encrypted Emails

Example

Encrypting online credit card payments.

MGI Tags

  • mgiPGP
  • mgiSendMail
  • mgiFieldContent

Steps

  1. Create a payment form and thank you page to process the payment form.
  2. Open the thank you page in a text editor.
  3. Insert the mgiPGP tag.
  4. Save the thank you page.
  5. FTP the thank you page to the web server running MGI.
  6. Install PGP software on your computer.
  7. Complete and submit the payment form.


Step 1: Create a request form and thank you page.

Create a payment form and thank you page to process the payment and send an email. See the Beginner "Processing Forms to Email" Tutorial for the steps to create a form and thank you page.

Step 2: Open the thank you page in a text editor.

Open the thank you page in a text editing program that allows you to modify the HTML of the page.

Step 3: Insert the mgiPGP tag.

Within the body of the mgiSendMail tag, insert a beginning and ending mgiPGP tag. Enter the beginning mgiPGP tag, function parameter, and passphraseFileLocation parameter before the email content and enter the ending mgiPGP tag after the email content (i.e., the mgiPGP tags should enclose the email content). In the function parameter, enter "encryptWithPhrase". In the passphraseFileLocation parameter, enter the path to the passphrase file (at the current file level or below) that includes the encryption phrase. Note: the passphrase file itself or a folder in the path to the passphrase file should be password protected by a WebSTAR realm. If you administer the server, you can set the realm. If you are hosted on a virtual server, a specific folder name or file name may be required. Contact your system administrator for the required folder or file name.
<mgiSendMail to="accounting@domain.com" from="webmaster@domain.com" 
subject="Payment" mailserver="mail.domain.com">

<mgiPGP function="encryptWithPhrase" 
passphraseFileLocation="encryptionPassphrase/phrase.txt">

<mgiFieldContent name="Account">
<mgiFieldContent name="CreditCardType">
<mgiFieldContent name="CreditCardNumber">
<mgiFieldContent name="ExpireMonth">
<mgiFieldContent name="ExpireYear">

</mgiPGP>

</mgiSendMail>

Step 4: Save the thank you page.

Save the changes you have made to the thank you page.

Step 5: FTP the thank you page to the web server running MGI.

Upload the thank you page from your local computer to the web server using an FTP program.

Step 6: Install PGP software on your computer.

In order to read an ecrypted email you must install PGP software on your computer to decrypt the email. Free PGP software can be found at http://web.mit.edu/network/pgp.html.

Step 7: Complete and submit the payment form.

Access the payment form in a browser. Complete and submit the form. Upon submission, an encrypted email is sent and the thank you page is displayed. When the email is received, decrypt it with the passphrase from the passphrase file using PGP software.


[Return to the Processing Forms to Email Menu]


[User Guide Main Menu] [Understanding MGI Menu] [Using MGI Menu] [Referencing MGI Menu]