just to say if you have a third-party firewall it may not allow you to do this, depending on settings; you may need to approach this directly in that software

I just block the program access to the internet completely - then allow briefly on the rare occasion I need any online resource, [I don't do websites or cloud]; and when the program needs to check activation once in a while [three months as I recall]