it is best to avoid windows 10 right now, but i don't think this is the case, of the first hacking attempt from microsoft, so it most likely that you were infected
you visited a shady website or probably downloaded something malicious, in other words it's your fault