+#else
+ int error = 0;
+ HCRYPTPROV crypt_prov = 0;
+
+ CryptAcquireContext(&crypt_prov, NULL, NULL,
+ PROV_RSA_FULL, CRYPT_VERIFYCONTEXT);
+ if (!CryptGenRandom(crypt_prov, n, buffer)) {
+ VLOG_ERR("CryptGenRandom: read error (%s)", ovs_lasterror_to_string());
+ error = EINVAL;
+ }
+
+ CryptReleaseContext(crypt_prov, 0);
+#endif