         TOKEN_ADJUST_GROUPS
         TOKEN_ADJUST_SESSIONID
         TOKEN_ADJUST_DEFAULT
-    } flags ; foldable
+    }
 
 CONSTANT: HKEY_CLASSES_ROOT        HEX: 80000000
 CONSTANT: HKEY_CURRENT_USER        HEX: 80000001

CONSTANT: TOKEN_QUERY                  HEX: 0008
CONSTANT: TOKEN_QUERY_SOURCE           HEX: 0010
CONSTANT: TOKEN_ADJUST_DEFAULT         HEX: 0080
: TOKEN_READ ( -- n ) { STANDARD_RIGHTS_READ TOKEN_QUERY } flags ;

: TOKEN_WRITE ( -- n )
    {
        STANDARD_RIGHTS_WRITE
        TOKEN_ADJUST_PRIVILEGES
        TOKEN_ADJUST_GROUPS
        TOKEN_ADJUST_DEFAULT
    } flags ; foldable

: TOKEN_ALL_ACCESS ( -- n )
    {
        STANDARD_RIGHTS_REQUIRED
        TOKEN_ASSIGN_PRIMARY
        TOKEN_DUPLICATE

ALIAS: CryptAcquireContext CryptAcquireContextW

! : CryptContextAddRef ;
FUNCTION: BOOL CryptCreateHash ( HCRYPTPROV hProv, ALG_ID Algid, HCRYPTKEY hKey, DWORD dwFlags, HCRYPTHASH *pHash ) ;
! : CryptDecrypt ;
! : CryptDeriveKey ;
! : CryptDestroyHash ;
