Feature toggle for csp (enable/disable)

In a particular situation, it would be nice to have a flag to disable the CSP reporting function, I think in case for example of dos, o whatever other things.
So I ask you if it is possible add this functionality