Security-PGP
2
PGP Security
This extension adds PGP security on endpoint communication. With PGP
you can achieve end-to-end security communication with signed and
encrypted messages between parties.
3
Requirements
Policy Files
If you are running JDK 1.4+ that comes with the Sun JCE by default, you
must install the Unlimited Strength Jurisdiction Policy files, which can be
downloaded from the following URL (note that they are listed entirely at the
bottom of the page, in the Other Downloads section):
JDK 1.4
JDK 5
JDK 6
These files must be installed in $JAVA_HOME$/jre/lib/security
4
According to Sun, the default distribution of the JCE allows "strong, but
limited strength cryptography." This means that you cannot use RSA keys
bigger than 2048 bits and no symmetric ciphers that use more than 128
bits. ElGamal is not allowed at all, thus DH/DSS cannot be used for
encryption.
5
Encrypting and Decrypting
To encrypt and decrypt messages you need to configure the following
elements:
A security manager: responsible of holding a security provider, which
contains the key rings, and the encryption strategy to be used. This allows
for the encryption of all messages using the same key or to facilitate the
use of different key rings.
A key manager: which is responsible for reading the key rings.
A credential accessor: which determines the key ring and key manager to
be used to encrypt/decrypt the message being processed.
6
Example
<spring:beans>
<spring:bean id="pgpKeyManager" class="org.mule.module.pgp.PGPKeyRingImpl"
init-method="initialise">
<spring:property name="publicKeyRingFileName" value="pubring.gpg"/>
<spring:property name="secretKeyRingFileName" value="secring.gpg"/>
<spring:property name="secretAliasId" value="$
{public.KeyId.LongValue}"/>
<spring:property name="secretPassphrase" value="$
{secret.Passphrase}"/>
</spring:bean>
<spring:bean id="credentialAccessor"
class="com.somecompany.apps.AppCredentialAccessor">
<spring:property name="credentials" value="John Smith (TestingKey)
&lt;john.smith@somecompany.com&gt;"/>
</spring:bean>
</spring:beans>
7
<pgp:security-manager>
<pgp:security-provider name="pgpSecurityProvider" keyManager-ref="pgpKeyManager"/>
<pgp:keybased-encryption-strategy
name="keyBasedEncryptionStrategy"
keyManager-ref="pgpKeyManager"
credentialsAccessor-ref="credentialAccessor"/>
</pgp:security-manager>
8
The pgpKeyManager (in the spring:beans tag) is the one responsible for
reading the rings. You have to set all the parameters: public and secret
rings, the alias id (the long value in the ring) and the secret passphrase. In
the same section, you can see the credentials accessor which needs to
implement the CredentialsAccessor interface basically returning the key id
based on the message (MuleEvent). Finally the pgp:security-manager
glues both beans.
9
You are ready to encrypt and decrypt messages in your flows. The
following two flows show how to use the encrypt-transformer and decrypt-
transformer to encrypt and decrypt files.
10
<flow name="processEncryptFiles">
<file:inbound-endpoint connector-ref="inputEncrypt"
path="file:///temp/fileInput" moveToDirectory="file:///temp/fileInputBackup"
moveToPattern="#[header:originalFilename].backup" transformer-
refs="file2Bytes" />
<encrypt-transformer name="pgpEncrypt"
strategy-ref="keyBasedEncryptionStrategy" />
<file:outbound-endpoint connector-ref="output"
path="file:///temp/fileOutput" outputPattern="#[function:datestamp]-
#[header:originalFilename]" />
</flow>
<flow name="processDecryptFiles">
<file:inbound-endpoint connector-ref="inputDecrypt"
path="file:///temp/fileOutput" moveToDirectory="file:///temp/fileOutputEncrypted"
moveToPattern="#[header:originalFilename].backup" transformer-
refs="file2Bytes" />
<decrypt-transformer name="pgpDecrypt"
strategy-ref="keyBasedEncryptionStrategy" />
<file:outbound-endpoint connector-ref="output"
path="file:///temp/fileOutputDecrypted" outputPattern="#[function:datestamp]-
#[header:originalFilename]" />
</flow>
Mule  security - pgp

More Related Content

PPT
Mule security - pgp
PPT
Mule security pgp with Example
PPTX
Pgp security mule
PPTX
Using pgp with mule
PDF
Safer Online Communication
PDF
Web security at Meteor (Pivotal Labs)
DOCX
key-aggregate cryptosystem for scalable data sharing in cloud storage
PPTX
Home network security
Mule security - pgp
Mule security pgp with Example
Pgp security mule
Using pgp with mule
Safer Online Communication
Web security at Meteor (Pivotal Labs)
key-aggregate cryptosystem for scalable data sharing in cloud storage
Home network security

What's hot (14)

PDF
Meteor Meets Mallory
PPTX
MongoDB.local DC 2018: Simplified Encryption & Key Management for MongoDB
PPTX
Cassandra
PPT
ssl
PPT
Sniffing SSL Traffic
PDF
Safety first – best practices in app security​
PPTX
Ssl in a nutshell
PPTX
Introduction to SSL and How to Exploit & Secure
PPTX
Ssl certificate in internet world
PPTX
cryptography security
PDF
Let's Encrypt! Wait. Why? How? - WC Pune
PDF
Let's Encrypt! Wait. Why? How?
PDF
Hashgraph vs Blockchain | Hedera Hashgraph Tutorial | Hashgraph Technology | ...
Meteor Meets Mallory
MongoDB.local DC 2018: Simplified Encryption & Key Management for MongoDB
Cassandra
ssl
Sniffing SSL Traffic
Safety first – best practices in app security​
Ssl in a nutshell
Introduction to SSL and How to Exploit & Secure
Ssl certificate in internet world
cryptography security
Let's Encrypt! Wait. Why? How? - WC Pune
Let's Encrypt! Wait. Why? How?
Hashgraph vs Blockchain | Hedera Hashgraph Tutorial | Hashgraph Technology | ...
Ad

Viewers also liked (20)

PPT
Mule saas
PDF
How to make ... Smore
PDF
TEDxUCDavis SAV(vy) Orientation
PDF
veverka DE65 Opinion
PPTX
Roofer westchester county ny
PDF
Transformando eficientemente resultados de uma consulta jdbc para json
DOCX
Rúbricas Clásicos Escolares Tarea del Módulo 3
PPT
Maven in Mule
PDF
Aprenentatge Basat en Projectes: Nivells i vies de transició.
PDF
Katastatiko neognologikis
PPTX
Les controvèrsies com a contexts rellevants per a l'experimentació a les aules.
PPTX
Kahoot questions
PDF
Estrategias para evitar reingresos
PDF
Guía de lectura. los doce trabajos de hércules Clásicos Escolares 15/16
PPTX
Μαριάννα - Αυτόχθονες λαοί
PPTX
λαπωνια
PDF
Introdução a RAML - parte 1
PPTX
Service orchestration by using flows
PPTX
Mule esb for beginners
Mule saas
How to make ... Smore
TEDxUCDavis SAV(vy) Orientation
veverka DE65 Opinion
Roofer westchester county ny
Transformando eficientemente resultados de uma consulta jdbc para json
Rúbricas Clásicos Escolares Tarea del Módulo 3
Maven in Mule
Aprenentatge Basat en Projectes: Nivells i vies de transició.
Katastatiko neognologikis
Les controvèrsies com a contexts rellevants per a l'experimentació a les aules.
Kahoot questions
Estrategias para evitar reingresos
Guía de lectura. los doce trabajos de hércules Clásicos Escolares 15/16
Μαριάννα - Αυτόχθονες λαοί
λαπωνια
Introdução a RAML - parte 1
Service orchestration by using flows
Mule esb for beginners
Ad

Similar to Mule security - pgp (20)

PPTX
Encrption in mule
PPTX
Using pgp with mule
PDF
Using PGP for securing the e-mail
PPTX
E mail security
PPTX
Mulesoft encryption
PPTX
Using PGP for securing the email
PPT
PGP S/MIME
PPTX
Mulesoft Meetup Cryptography Module
PPTX
Ahmadabad mule soft_meetup_17april2021_mule4_cryptography
PPT
Lecture 8 mail security
PPTX
Pgp pretty good privacy
PDF
E-mail Security Protocol - 2 Pretty Good Privacy (PGP)
PPT
Pgp smime
PPTX
Email sec11
PDF
PGP Encryption And Decryption With Mule ESB
PPT
electronic mail security for authent.ppt
Encrption in mule
Using pgp with mule
Using PGP for securing the e-mail
E mail security
Mulesoft encryption
Using PGP for securing the email
PGP S/MIME
Mulesoft Meetup Cryptography Module
Ahmadabad mule soft_meetup_17april2021_mule4_cryptography
Lecture 8 mail security
Pgp pretty good privacy
E-mail Security Protocol - 2 Pretty Good Privacy (PGP)
Pgp smime
Email sec11
PGP Encryption And Decryption With Mule ESB
electronic mail security for authent.ppt

More from charan teja R (20)

PPT
Mule cloud hub console overview
PPT
Mule deploying a cloud hub application
PPT
Security spring security manager
PPT
Security authorization using spring security
PPT
Anypoint data gateway
PPT
Mule B2B
PPT
Mule security
PPT
Mule security - jaas
PPT
Mule security - saml
PPT
Mule anypoint workday-devkit
PPT
Mule anypoint workday-connectors
PPTX
Mule esb
PPT
Mule connectors
PPT
Mule microsoft environment
PPT
Mule esb–api layer
PPT
Mule salesforce integration solutions
DOCX
Mule with jdbc(my sql)
PPTX
Mule esb usecase
PPT
Mule saas
PPTX
Mule esb
Mule cloud hub console overview
Mule deploying a cloud hub application
Security spring security manager
Security authorization using spring security
Anypoint data gateway
Mule B2B
Mule security
Mule security - jaas
Mule security - saml
Mule anypoint workday-devkit
Mule anypoint workday-connectors
Mule esb
Mule connectors
Mule microsoft environment
Mule esb–api layer
Mule salesforce integration solutions
Mule with jdbc(my sql)
Mule esb usecase
Mule saas
Mule esb

Recently uploaded (20)

PPTX
SGT Report The Beast Plan and Cyberphysical Systems of Control
PDF
A symptom-driven medical diagnosis support model based on machine learning te...
PDF
Enhancing plagiarism detection using data pre-processing and machine learning...
PDF
Transform-Your-Streaming-Platform-with-AI-Driven-Quality-Engineering.pdf
PDF
Rapid Prototyping: A lecture on prototyping techniques for interface design
PPTX
AI-driven Assurance Across Your End-to-end Network With ThousandEyes
PDF
CXOs-Are-you-still-doing-manual-DevOps-in-the-age-of-AI.pdf
PDF
Connector Corner: Transform Unstructured Documents with Agentic Automation
PDF
Dell Pro Micro: Speed customer interactions, patient processing, and learning...
PDF
Comparative analysis of machine learning models for fake news detection in so...
PDF
4 layer Arch & Reference Arch of IoT.pdf
PDF
Transform-Your-Supply-Chain-with-AI-Driven-Quality-Engineering.pdf
PDF
Data Virtualization in Action: Scaling APIs and Apps with FME
PDF
EIS-Webinar-Regulated-Industries-2025-08.pdf
PDF
5-Ways-AI-is-Revolutionizing-Telecom-Quality-Engineering.pdf
PDF
INTERSPEECH 2025 「Recent Advances and Future Directions in Voice Conversion」
PDF
Electrocardiogram sequences data analytics and classification using unsupervi...
PDF
Transform-Quality-Engineering-with-AI-A-60-Day-Blueprint-for-Digital-Success.pdf
PDF
Accessing-Finance-in-Jordan-MENA 2024 2025.pdf
PDF
Planning-an-Audit-A-How-To-Guide-Checklist-WP.pdf
SGT Report The Beast Plan and Cyberphysical Systems of Control
A symptom-driven medical diagnosis support model based on machine learning te...
Enhancing plagiarism detection using data pre-processing and machine learning...
Transform-Your-Streaming-Platform-with-AI-Driven-Quality-Engineering.pdf
Rapid Prototyping: A lecture on prototyping techniques for interface design
AI-driven Assurance Across Your End-to-end Network With ThousandEyes
CXOs-Are-you-still-doing-manual-DevOps-in-the-age-of-AI.pdf
Connector Corner: Transform Unstructured Documents with Agentic Automation
Dell Pro Micro: Speed customer interactions, patient processing, and learning...
Comparative analysis of machine learning models for fake news detection in so...
4 layer Arch & Reference Arch of IoT.pdf
Transform-Your-Supply-Chain-with-AI-Driven-Quality-Engineering.pdf
Data Virtualization in Action: Scaling APIs and Apps with FME
EIS-Webinar-Regulated-Industries-2025-08.pdf
5-Ways-AI-is-Revolutionizing-Telecom-Quality-Engineering.pdf
INTERSPEECH 2025 「Recent Advances and Future Directions in Voice Conversion」
Electrocardiogram sequences data analytics and classification using unsupervi...
Transform-Quality-Engineering-with-AI-A-60-Day-Blueprint-for-Digital-Success.pdf
Accessing-Finance-in-Jordan-MENA 2024 2025.pdf
Planning-an-Audit-A-How-To-Guide-Checklist-WP.pdf

Mule security - pgp

  • 2. 2 PGP Security This extension adds PGP security on endpoint communication. With PGP you can achieve end-to-end security communication with signed and encrypted messages between parties.
  • 3. 3 Requirements Policy Files If you are running JDK 1.4+ that comes with the Sun JCE by default, you must install the Unlimited Strength Jurisdiction Policy files, which can be downloaded from the following URL (note that they are listed entirely at the bottom of the page, in the Other Downloads section): JDK 1.4 JDK 5 JDK 6 These files must be installed in $JAVA_HOME$/jre/lib/security
  • 4. 4 According to Sun, the default distribution of the JCE allows "strong, but limited strength cryptography." This means that you cannot use RSA keys bigger than 2048 bits and no symmetric ciphers that use more than 128 bits. ElGamal is not allowed at all, thus DH/DSS cannot be used for encryption.
  • 5. 5 Encrypting and Decrypting To encrypt and decrypt messages you need to configure the following elements: A security manager: responsible of holding a security provider, which contains the key rings, and the encryption strategy to be used. This allows for the encryption of all messages using the same key or to facilitate the use of different key rings. A key manager: which is responsible for reading the key rings. A credential accessor: which determines the key ring and key manager to be used to encrypt/decrypt the message being processed.
  • 6. 6 Example <spring:beans> <spring:bean id="pgpKeyManager" class="org.mule.module.pgp.PGPKeyRingImpl" init-method="initialise"> <spring:property name="publicKeyRingFileName" value="pubring.gpg"/> <spring:property name="secretKeyRingFileName" value="secring.gpg"/> <spring:property name="secretAliasId" value="$ {public.KeyId.LongValue}"/> <spring:property name="secretPassphrase" value="$ {secret.Passphrase}"/> </spring:bean> <spring:bean id="credentialAccessor" class="com.somecompany.apps.AppCredentialAccessor"> <spring:property name="credentials" value="John Smith (TestingKey) &lt;[email protected]&gt;"/> </spring:bean> </spring:beans>
  • 8. 8 The pgpKeyManager (in the spring:beans tag) is the one responsible for reading the rings. You have to set all the parameters: public and secret rings, the alias id (the long value in the ring) and the secret passphrase. In the same section, you can see the credentials accessor which needs to implement the CredentialsAccessor interface basically returning the key id based on the message (MuleEvent). Finally the pgp:security-manager glues both beans.
  • 9. 9 You are ready to encrypt and decrypt messages in your flows. The following two flows show how to use the encrypt-transformer and decrypt- transformer to encrypt and decrypt files.
  • 10. 10 <flow name="processEncryptFiles"> <file:inbound-endpoint connector-ref="inputEncrypt" path="file:///temp/fileInput" moveToDirectory="file:///temp/fileInputBackup" moveToPattern="#[header:originalFilename].backup" transformer- refs="file2Bytes" /> <encrypt-transformer name="pgpEncrypt" strategy-ref="keyBasedEncryptionStrategy" /> <file:outbound-endpoint connector-ref="output" path="file:///temp/fileOutput" outputPattern="#[function:datestamp]- #[header:originalFilename]" /> </flow> <flow name="processDecryptFiles"> <file:inbound-endpoint connector-ref="inputDecrypt" path="file:///temp/fileOutput" moveToDirectory="file:///temp/fileOutputEncrypted" moveToPattern="#[header:originalFilename].backup" transformer- refs="file2Bytes" /> <decrypt-transformer name="pgpDecrypt" strategy-ref="keyBasedEncryptionStrategy" /> <file:outbound-endpoint connector-ref="output" path="file:///temp/fileOutputDecrypted" outputPattern="#[function:datestamp]- #[header:originalFilename]" /> </flow>