The dynamical generation of wormholes within an extension of General Relativity (GR) containing (Planck's scale-suppressed) Ricci-squared terms is considered. The theory is formulated assuming the metric and connection to be independent (Palatini formalism) and is probed using a charged null fluid as a matter source. This has the following effect: starting from Minkowski space, when the flux is active the metric becomes a charged Vaidya-type one, and once the flux is switched off the metric settles down into a static configuration such that far from the Planck scale the geometry is virtually indistinguishable from that of the standard Reissner-Nordstr\"om solution of GR. However, the innermost region undergoes significant changes, as the GR singularity is generically replaced by a wormhole structure. Such a structure becomes completely regular for a certain charge-to-mass ratio. Moreover, the nontrivial topology of the wormhole allows to define a charge in terms of lines of force trapped in the topology such that the density of lines flowing across the wormhole throat becomes a universal constant. To the light of our results we comment on the physical significance of curvature divergences in this theory and the topology change issue, which support the view that space-time could have a foam-like microstructure pervaded by wormholes generated by quantum gravitational effects.