Air molecules scatter moonlight the same way they scatter sunlight (Rayleigh scattering, cross-section ∝ 1/λ⁴). For light singly-scattered once by an air molecule, the degree of linear polarization of the scattered light depends only on the scattering angle θ — the angle between the incoming ray from the Moon and the outgoing ray toward the observer:
P(θ) = sin²θ / (1 + cos²θ)
P(θ) is exactly zero looking straight at the Moon or straight away from it (θ = 0°/180°) and reaches its real maximum of 1 (fully polarized) at θ = 90° — the band of sky that forms a great circle 90° from the Moon. The scattered E-vector itself is always oriented perpendicular to the "scattering plane" containing the Moon, the air molecule, and the observer, which is why the polarization axis sweeps around the sky in the arced pattern some insects (and reportedly dung beetles, some moths) use for moonlit-night orientation.
Haze adds aerosol particles much larger than air molecules; light bounces through them multiple times before reaching the eye, and each extra scattering event randomizes the polarization a bit more, so real haze/multiple-scattering depolarizes the sky — the degree of polarization shown here is scaled down as the haze slider increases, exactly as it is in real atmospheric polarimetry.
The filter slider applies the actual law for a linear polarizer viewing partially-polarized light: transmission = (1−P)/2 + P·cos²(filter angle − local E-vector angle) — rotating a real polarizing filter through the sky darkens and brightens bands exactly like this.