congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
PlexusCipher.decrypt
Code IndexAdd Tabnine to your IDE (free)

How to use
decrypt
method
in
org.sonatype.plexus.components.cipher.PlexusCipher

Best Java code snippets using org.sonatype.plexus.components.cipher.PlexusCipher.decrypt (Showing top 4 results out of 315)

origin: io.fabric8/fabric-maven

@Override
public String decrypt(String str) throws SecDispatcherException {
  if (!isEncryptedString(str)) {
    return str;
  }
  String bare = null;
  try {
    bare = cipher.unDecorate(str);
  } catch (PlexusCipherException e1) {
    throw new SecDispatcherException(e1);
  }
  Map<String, String> attr = stripAttributes(bare);
  String res = null;
  if (attr == null || attr.get("type") == null) {
    String master = getMaster();
    try {
      res = cipher.decrypt(bare, master);
    } catch (PlexusCipherException e) {
      throw new SecDispatcherException("Unable to decrypt encrypted string", e);
    }
  }
  else {
    String type = (String) attr.get(TYPE_ATTR);
    throw new UnsupportedOperationException("Unable to lookup security dispatched of type " + type);
  }
  return res;
}
origin: org.jboss.shrinkwrap.resolver/shrinkwrap-resolver-impl-maven

@Override
public String decrypt(String str) throws SecDispatcherException {
  if (!isEncryptedString(str)) {
    return str;
  }
  String bare = null;
  try {
    bare = cipher.unDecorate(str);
  } catch (PlexusCipherException e1) {
    throw new SecDispatcherException(e1);
  }
  Map<String, String> attr = stripAttributes(bare);
  String res = null;
  if (attr == null || attr.get("type") == null) {
    String master = getMaster();
    try {
      res = cipher.decrypt(bare, master);
    } catch (PlexusCipherException e) {
      throw new SecDispatcherException("Unable to decrypt encrypted string", e);
    }
  }
  else {
    String type = (String) attr.get(TYPE_ATTR);
    throw new UnsupportedOperationException("Unable to lookup security dispatched of type " + type);
  }
  return res;
}
origin: shrinkwrap/resolver

@Override
public String decrypt(String str) throws SecDispatcherException {
  if (!isEncryptedString(str)) {
    return str;
  }
  String bare = null;
  try {
    bare = cipher.unDecorate(str);
  } catch (PlexusCipherException e1) {
    throw new SecDispatcherException(e1);
  }
  Map<String, String> attr = stripAttributes(bare);
  String res = null;
  if (attr == null || attr.get("type") == null) {
    String master = getMaster();
    try {
      res = cipher.decrypt(bare, master);
    } catch (PlexusCipherException e) {
      throw new SecDispatcherException("Unable to decrypt encrypted string", e);
    }
  }
  else {
    String type = (String) attr.get(TYPE_ATTR);
    throw new UnsupportedOperationException("Unable to lookup security dispatched of type " + type);
  }
  return res;
}
origin: org.sonatype.plexus/plexus-sec-dispatcher

res = _cipher.decrypt( bare, master );
org.sonatype.plexus.components.cipherPlexusCipherdecrypt

Popular methods of PlexusCipher

  • isEncryptedString
  • decryptDecorated
  • unDecorate
  • encryptAndDecorate

Popular in Java

  • Creating JSON documents from java classes using gson
  • setContentView (Activity)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getContentResolver (Context)
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Set (java.util)
    A Set is a data structure which does not allow duplicate elements.
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now