if (mechFilters != null && CollectionUtil.isNonEmpty(mechFilters)) { for (Pkcs11conf.MechanimFilter filterType : mechFilters) { Set<P11SlotIdFilter> slots = getSlotIdFilters(filterType.getSlots()); String mechanismSetName = filterType.getMechanismSet(); passwordRetriever.setPasswordResolver(passwordResolver); for (Pkcs11conf.PasswordSet passwordType : passwordsList) { Set<P11SlotIdFilter> slots = getSlotIdFilters(passwordType.getSlots()); passwordRetriever.addPasswordEntry(slots, new ArrayList<>(passwordType.getPasswords())); includeSlots = getSlotIdFilters(moduleType.getIncludeSlots()); excludeSlots = getSlotIdFilters(moduleType.getExcludeSlots());
if (mechsList != null && CollectionUtil.isNonEmpty(mechsList.getMechanisms())) { for (MechanismsType mechType : mechsList.getMechanisms()) { Set<P11SlotIdFilter> slots = getSlotIdFilters(mechType.getSlots()); Set<Long> mechanisms = new HashSet<>(); for (String mechStr : mechType.getMechanism()) { passwordRetriever.setPasswordResolver(passwordResolver); for (PasswordsType passwordType : passwordsList.getPasswords()) { Set<P11SlotIdFilter> slots = getSlotIdFilters(passwordType.getSlots()); passwordRetriever.addPasswordEntry(slots, new ArrayList<>(passwordType.getPassword())); includeSlots = getSlotIdFilters(moduleType.getIncludeSlots()); excludeSlots = getSlotIdFilters(moduleType.getExcludeSlots());
if (mechFilters != null && CollectionUtil.isNonEmpty(mechFilters.getMechanismFilter())) { for (MechanismFilterType filterType : mechFilters.getMechanismFilter()) { Set<P11SlotIdFilter> slots = getSlotIdFilters(filterType.getSlots()); String mechanismSetName = filterType.getMechanismSet(); passwordRetriever.setPasswordResolver(passwordResolver); for (PasswordsType passwordType : passwordsList.getPasswords()) { Set<P11SlotIdFilter> slots = getSlotIdFilters(passwordType.getSlots()); passwordRetriever.addPasswordEntry(slots, new ArrayList<>(passwordType.getPassword())); includeSlots = getSlotIdFilters(moduleType.getIncludeSlots()); excludeSlots = getSlotIdFilters(moduleType.getExcludeSlots());