This is strange.The encryption requirement should have nothing to do with the OS.
Can you please attach the project here along with the steps to reproduce?
Encryption routines are sensitive to variable types/declaration differences on OS. It could be that one of these changed in implementation betwen windows 7 and 10, thus causing the encryption library to fail due to variable size/type, leading to the error you are seeing.
Thanks everyone for your answers and suggestions. We have removed pairing from our device firmware, So now everything is working without pairing.
Now I am little busy, So I did not get time to look into this but surely I will look after this and will try your suggestions.