One way to fix the problem would be to somehow feed Copilot a corpora of closed source code. This would either force Microsoft to add necessary copyright protections, or - which is imho more likely - would prove that those protections are already in place, but disabled for open source code.
A good start would be to take a leaked code of Windows, and then mechanically adjust all the names, constant values, and code formatting, and then publish it and observe.
A good start would be to take a leaked code of Windows, and then mechanically adjust all the names, constant values, and code formatting, and then publish it and observe.