| | |
| | | |
| | | |
| | | |
| | | /** |
| | | * Creates a new MD4 message digest algorithm. |
| | | */ |
| | | /** Creates a new MD4 message digest algorithm. */ |
| | | MD4MessageDigest() |
| | | { |
| | | super("MD4"); |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public byte[] engineDigest() |
| | | { |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void engineReset() |
| | | { |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void engineUpdate(final byte input) |
| | | { |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void engineUpdate(final byte[] in, int inOff, int len) |
| | | { |
| | |
| | | |
| | | |
| | | |
| | | /* |
| | | * rotate int x left n bits. |
| | | */ |
| | | /** Rotate int x left n bits. */ |
| | | private int rotateLeft(final int x, final int n) |
| | | { |
| | | return (x << n) | (x >>> 32 - n); |
| | |
| | | |
| | | |
| | | |
| | | /** |
| | | * Plugin configuration object. |
| | | */ |
| | | /** Plugin configuration object. */ |
| | | private SambaPasswordPluginCfg config; |
| | | |
| | | /** The name of the Samba LanMan password attribute. */ |
| | |
| | | |
| | | |
| | | |
| | | /** |
| | | * Default constructor. |
| | | */ |
| | | /** Default constructor. */ |
| | | public SambaPasswordPlugin() |
| | | { |
| | | super(); |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public ConfigChangeResult applyConfigurationChange( |
| | | final SambaPasswordPluginCfg newConfig) |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public PluginResult.PostOperation doPostOperation( |
| | | final PostOperationExtendedOperation extendedOperation) |
| | | { |
| | | /* |
| | | * If the operation is not Password Modify Extended Operation then skip this |
| | | * operation. |
| | | */ |
| | | /* If the operation is not Password Modify Extended Operation then skip this operation. */ |
| | | if (!extendedOperation.getRequestOID().equals(PWMOD_EXTOP_OID)) |
| | | { |
| | | return PluginResult.PostOperation.continueOperationProcessing(); |
| | | } |
| | | |
| | | /* |
| | | * If the operation has not been successful then ignore the operation. |
| | | */ |
| | | /* If the operation has not been successful then ignore the operation. */ |
| | | if (extendedOperation.getResultCode() != ResultCode.SUCCESS) |
| | | { |
| | | return PluginResult.PostOperation.continueOperationProcessing(); |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public PluginResult.PreOperation doPreOperation( |
| | | final PreOperationModifyOperation modifyOperation) |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void initializePlugin(final Set<PluginType> pluginTypes, |
| | | final SambaPasswordPluginCfg configuration) throws ConfigException, |
| | |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public boolean isConfigurationChangeAcceptable( |
| | | final SambaPasswordPluginCfg newConfig, final List<LocalizableMessage> messages) |
| | |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * Timestamp provider interface. Intended primarily for testing purposes. |
| | | */ |
| | | /** Timestamp provider interface. Intended primarily for testing purposes. */ |
| | | static interface TimeStampProvider |
| | | { |
| | | /** |