Package hudson.util
Class SecretRewriter
java.lang.Object
hudson.util.SecretRewriter
Rewrites XML files by looking for Secrets that are stored with the old key and replaces them
by the new encrypted values.
- Author:
- Kohsuke Kawaguchi
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
isIgnoredDir
(File dir) Decides if this directory is worth visiting or not.boolean
boolean
Deprecated.SECURITY-376:backup
is ignoredint
rewriteRecursive
(File dir, TaskListener listener) Recursively scans and rewrites a directory.
-
Constructor Details
-
SecretRewriter
- Throws:
GeneralSecurityException
-
SecretRewriter
Deprecated.SECURITY-376:backupDirectory
is ignored- Throws:
GeneralSecurityException
-
-
Method Details
-
rewrite
Deprecated.SECURITY-376:backup
is ignored- Throws:
InvalidKeyException
IOException
-
rewrite
- Throws:
InvalidKeyException
IOException
-
rewriteRecursive
Recursively scans and rewrites a directory. This method shouldn't abort just because one file fails to rewrite.- Returns:
- Number of files that were actually rewritten.
- Throws:
InvalidKeyException
-
isIgnoredDir
Decides if this directory is worth visiting or not.
-
backupDirectory
is ignored