Security of the conventional Fourier-based double-random-phase encryption (DRPE) technique is prone to impulse attacks, as the Fourier transform (FT) of a delta function results in a unity function. To negate such an attack, the phase factors of the lenses are modified by multiplying these with random-phase functions. Owing to this modification of the FT as a result of the randomized lens phase function, a modified FT (MFTLR) gives the random output for a delta function input. Employing MFTLR in the DRPE technique enhances the security features and makes the encryption system safer from the impulse attack. Numerical and experimental results are given for the validation of the proposed technique.