Over the years I have come across many wheel rims that have corroded on the inside next to where the tube valve and/or rim lock fits. Water (and maybe even salty water in the winter) gets in and starts the corrosion.
The best way to prevent this happening is quite simple. Fit seals to the tube valves and a rim lock nut with a washer shaped to the wheel rim.
I have just updated the wheels on my current project bike with these - see the photos below.
The Schrader valve fitted in the last photo is also useful to have as it gives a really good seal on the valve stem and has a slot in its top to use when removing/replacing the valves - see here.