Example: pre-image resistance to second pre-image resistance

It is possible to convert a pre-image resistant function $f:\{0,1\}^{n}\rightarrow \{0,1\}^{n}$ to a second-preimage resistant function? I am thinking to use a pseudo-random generator and construct that second pre-image resistant function in this way:

$$F(x)=f(x)+\text{PRNG}(x).$$

What kind of tests I need to make to verify this function is second-preimage resistant?

• Just let me quickly recap this: $f$ is pre-image resistant and $F$ should be pre-image resistant and second pre-image resistant? Jul 26, 2015 at 13:01
• @SEJPM Yes it is Jul 26, 2015 at 13:06
• – otus
Jul 26, 2015 at 13:30
• @mikeazo The length preservation indeed makes things a bit trivial. to "convert" just ignore the function and use the identity function instead (or any other permutation for that matter). Since there is only one preimage for each image, there can be no second preimage attack. Jul 29, 2015 at 16:04
• @Maeher but with the identity function, you don't have preimage resistance. Jul 29, 2015 at 16:23