1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
package org.mule.umo.security; |
12 | |
|
13 | |
import org.mule.MuleException; |
14 | |
import org.mule.config.i18n.CoreMessages; |
15 | |
import org.mule.config.i18n.Message; |
16 | |
import org.mule.umo.UMOEncryptionStrategy; |
17 | |
|
18 | |
|
19 | |
|
20 | |
|
21 | |
|
22 | |
|
23 | |
|
24 | |
|
25 | |
|
26 | |
|
27 | |
|
28 | |
|
29 | |
public class CryptoFailureException extends MuleException |
30 | |
{ |
31 | |
|
32 | |
|
33 | |
|
34 | |
private static final long serialVersionUID = 1336343718508294379L; |
35 | |
|
36 | |
private transient UMOEncryptionStrategy encryptionStrategy; |
37 | |
|
38 | |
public CryptoFailureException(Message message, UMOEncryptionStrategy strategy) |
39 | |
{ |
40 | 0 | super(message); |
41 | 0 | String s = (strategy == null ? "null" : strategy.toString()); |
42 | 0 | addInfo("Encryption", s); |
43 | 0 | this.encryptionStrategy = strategy; |
44 | 0 | } |
45 | |
|
46 | |
public CryptoFailureException(Message message, UMOEncryptionStrategy strategy, Throwable cause) |
47 | |
{ |
48 | 0 | super(message, cause); |
49 | 0 | String s = (strategy == null ? "null" : strategy.toString()); |
50 | 0 | addInfo("Encryption", s); |
51 | 0 | this.encryptionStrategy = strategy; |
52 | 0 | } |
53 | |
|
54 | |
public CryptoFailureException(UMOEncryptionStrategy strategy, Throwable cause) |
55 | |
{ |
56 | 0 | super(CoreMessages.cryptoFailure(), cause); |
57 | 0 | String s = (strategy == null ? "null" : strategy.toString()); |
58 | 0 | addInfo("Encryption", s); |
59 | 0 | this.encryptionStrategy = strategy; |
60 | |
|
61 | 0 | } |
62 | |
|
63 | |
public UMOEncryptionStrategy getEncryptionStrategy() |
64 | |
{ |
65 | 0 | return encryptionStrategy; |
66 | |
} |
67 | |
} |