* fhandler_random.cc (read): Use CRYPT_MACHINE_KEYSET in
call to CryptAcquireContext() to serve users that did not
        log in interactively.
			
			
This commit is contained in:
		@@ -43,10 +43,10 @@ fhandler_dev_random::read (void *ptr, size_t len)
 | 
			
		||||
  if (!len)
 | 
			
		||||
    return 0;
 | 
			
		||||
  if (!crypt_prov
 | 
			
		||||
      && !CryptAcquireContext (&crypt_prov, NULL, MS_DEF_PROV,
 | 
			
		||||
                            PROV_RSA_FULL, 0)
 | 
			
		||||
      && !CryptAcquireContext (&crypt_prov, NULL, MS_DEF_PROV,
 | 
			
		||||
                               PROV_RSA_FULL, CRYPT_NEWKEYSET))
 | 
			
		||||
      && !CryptAcquireContext (&crypt_prov, NULL, MS_DEF_PROV, PROV_RSA_FULL,
 | 
			
		||||
                               CRYPT_MACHINE_KEYSET)
 | 
			
		||||
      && !CryptAcquireContext (&crypt_prov, NULL, MS_DEF_PROV, PROV_RSA_FULL,
 | 
			
		||||
                               CRYPT_MACHINE_KEYSET | CRYPT_NEWKEYSET ))
 | 
			
		||||
    {
 | 
			
		||||
      __seterrno ();
 | 
			
		||||
      return -1;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user