Learn Account Access and Security (COF-C02) with Interactive Flashcards

Master key concepts in Account Access and Security through our interactive flashcard system. Click on each card to reveal detailed explanations and enhance your understanding.

Role-based access control (RBAC)

Role-based access control (RBAC) is a fundamental security framework in Snowflake that governs how users interact with objects and perform operations within the platform. RBAC operates on the principle that access permissions are assigned to roles rather than individual users, creating a more manageable and scalable security model.

In Snowflake, RBAC consists of several key components. Roles are named entities that can be granted privileges on securable objects such as databases, schemas, tables, warehouses, and more. Users are then assigned to these roles, inheriting all the privileges associated with them. This hierarchical structure allows for efficient permission management across large organizations.

Snowflake provides system-defined roles including ACCOUNTADMIN (the most powerful role with full account access), SECURITYADMIN (manages users and roles), SYSADMIN (creates and manages objects), and PUBLIC (automatically granted to all users). Organizations can also create custom roles tailored to specific business needs.

The RBAC model in Snowflake supports role hierarchy, where roles can be granted to other roles, creating parent-child relationships. Child roles inherit privileges from parent roles, enabling a cascading permission structure. This hierarchy simplifies administration when managing complex permission requirements.

Privileges in RBAC are granular and can be assigned at various levels. Common privileges include SELECT, INSERT, UPDATE, DELETE for tables, and USAGE for schemas and warehouses. The GRANT and REVOKE commands are used to manage these privileges.

Best practices for RBAC implementation include following the principle of least privilege, where users receive only the minimum permissions necessary for their tasks. Organizations should regularly audit role assignments, create functional roles aligned with job responsibilities, and avoid excessive use of ACCOUNTADMIN privileges.

RBAC integrates with other Snowflake security features like network policies and multi-factor authentication to provide comprehensive access control. Understanding RBAC is essential for the SnowPro Core Certification as it forms the foundation of Snowflake security architecture.

System-defined roles (ACCOUNTADMIN, SYSADMIN, SECURITYADMIN, etc.)

Snowflake provides several system-defined roles that form the foundation of access control within an account. These roles are created automatically and cannot be deleted. Understanding them is essential for the SnowPro Core Certification.

**ACCOUNTADMIN** is the most powerful role, combining the capabilities of SYSADMIN and SECURITYADMIN. It has full control over all objects and users in the account. This role should be assigned sparingly and used carefully, as it can manage billing, resource monitors, and account-level parameters. Best practice recommends enabling multi-factor authentication for users with this role.

**SYSADMIN** (System Administrator) is designed for creating and managing objects like warehouses, databases, schemas, and other database objects. It can grant privileges on objects it owns to other roles. SYSADMIN should be the parent role for all custom roles that own objects, ensuring proper hierarchy management.

**SECURITYADMIN** manages security aspects including users, roles, and grants. It owns the built-in USERADMIN role and can manage any grant in the account through its MANAGE GRANTS privilege. This role focuses on access control rather than object management.

**USERADMIN** is specifically for user and role management. It can create users and roles but has limited privileges compared to SECURITYADMIN. It possesses the CREATE USER and CREATE ROLE privileges.

**PUBLIC** is a special role automatically granted to every user and role in the account. Objects granted to PUBLIC become accessible to all users. Use this role cautiously when sharing access broadly.

**ORGADMIN** manages operations across an organization, including creating accounts, viewing usage across accounts, and enabling replication.

The recommended role hierarchy has ACCOUNTADMIN at the top, with SECURITYADMIN and SYSADMIN beneath it. USERADMIN falls under SECURITYADMIN, and custom roles should be granted to SYSADMIN to maintain proper access control structure.

Custom roles and role hierarchy

In Snowflake, custom roles and role hierarchy are fundamental components of the access control framework that enable organizations to implement fine-grained security policies. Snowflake uses Role-Based Access Control (RBAC) where privileges are assigned to roles, and roles are granted to users or other roles.

Custom roles are user-defined roles created to meet specific organizational security requirements. Unlike system-defined roles (ACCOUNTADMIN, SECURITYADMIN, SYSADMIN, USERADMIN, and PUBLIC), custom roles can be tailored to match your business needs. You create custom roles using the CREATE ROLE statement, and they can be granted specific privileges on database objects like warehouses, databases, schemas, tables, and views.

Role hierarchy is the structure where roles can be granted to other roles, creating a parent-child relationship. When Role A is granted to Role B, Role B inherits all privileges of Role A. This inheritance flows upward through the hierarchy. The ACCOUNTADMIN role sits at the top of the default hierarchy, inheriting privileges from SECURITYADMIN and SYSADMIN.

Best practices for role hierarchy include: creating custom roles for specific job functions, granting custom roles to system roles like SYSADMIN to maintain a connected hierarchy, and following the principle of least privilege. Roles that are not connected to the hierarchy cannot be used by ACCOUNTADMIN, which can create security blind spots.

The SECURITYADMIN role can manage grants globally and is typically responsible for creating and managing custom roles. Users can have multiple roles assigned but operate under one active role at a time, though they can use secondary roles to combine privileges.

Understanding role hierarchy is essential for the SnowPro Core exam, as it forms the foundation of Snowflakes security model and determines how users interact with objects and perform operations within the platform.

Privileges and privilege management

Privileges in Snowflake are fundamental components of the security model that determine what actions users and roles can perform on objects within the account. They form the foundation of Snowflake's Role-Based Access Control (RBAC) system, enabling administrators to precisely control access to data and resources.

Snowflake implements two types of privileges: system-defined privileges and object privileges. System-defined privileges control account-level operations such as creating warehouses, databases, and managing users. Object privileges govern actions on specific objects like tables, views, schemas, and stages.

Key privilege categories include:

1. **USAGE** - Allows access to an object (databases, schemas, warehouses)
2. **SELECT** - Permits reading data from tables and views
3. **INSERT, UPDATE, DELETE** - Enable data modification operations
4. **CREATE** - Allows creating new objects within a container
5. **OWNERSHIP** - Grants full control over an object, including the ability to grant privileges to others

Privilege management in Snowflake follows the principle of least privilege, meaning users should only receive the minimum permissions necessary for their tasks. Administrators use GRANT and REVOKE statements to manage privileges. The GRANT command assigns privileges to roles, while REVOKE removes them.

Best practices for privilege management include:

- Creating custom roles aligned with job functions
- Granting privileges to roles rather than individual users
- Establishing role hierarchies where higher-level roles inherit privileges from lower-level roles
- Using the ACCOUNTADMIN role sparingly and only when necessary
- Regularly auditing privilege assignments using the ACCESS_HISTORY and GRANTS views
- Implementing the concept of separation of duties

Snowflake provides several system-defined roles including ACCOUNTADMIN, SECURITYADMIN, SYSADMIN, and PUBLIC, each with specific default privileges. Understanding these roles and how to extend them through custom role creation is essential for maintaining a secure and well-organized Snowflake environment.

Object ownership and access

Object ownership and access in Snowflake is a fundamental security concept that determines who can perform actions on database objects. Every object in Snowflake has an owner, which is the role that created the object. This ownership model is central to Snowflake's role-based access control (RBAC) system.

When a role creates an object such as a table, view, schema, or database, that role automatically becomes the owner. The owner role has full control over the object, including the ability to grant privileges to other roles, modify the object, or drop it entirely. Ownership can be transferred to another role using the GRANT OWNERSHIP command.

Access to objects is controlled through privileges. Snowflake uses a hierarchical privilege system where roles can be granted specific permissions on objects. Common privileges include SELECT, INSERT, UPDATE, DELETE for tables, and USAGE for databases, schemas, and warehouses. The USAGE privilege is particularly important as it allows a role to access an object but does not grant any specific action privileges.

Snowflake follows the principle of least privilege, meaning users should only have the minimum permissions necessary to perform their tasks. Privileges can be granted at various levels: account, database, schema, or individual object level. When granted at higher levels, privileges cascade down to contained objects.

The ACCOUNTADMIN role is the top-level administrative role with full access to all objects. SECURITYADMIN manages security-related tasks including granting privileges. SYSADMIN typically owns warehouses and databases.

Future grants allow administrators to pre-define privileges that will be automatically applied to objects created in the future within a specific schema or database. This simplifies access management for new objects.

Understanding object ownership and access control is essential for maintaining data security, ensuring proper data governance, and implementing effective access policies within your Snowflake environment.

User authentication methods

User authentication in Snowflake refers to the various methods used to verify the identity of users attempting to access the Snowflake platform. Understanding these methods is essential for the SnowPro Core Certification exam.

**Password-Based Authentication** is the most basic method where users provide a username and password combination. Snowflake stores passwords securely using strong hashing algorithms. Administrators can enforce password policies including minimum length, complexity requirements, and expiration periods.

**Multi-Factor Authentication (MFA)** adds an extra security layer by requiring users to provide a second form of verification through the Duo Security service. Users must enter a one-time code from their mobile device after providing their password. MFA can be enabled per user and is highly recommended for enhanced security.

**Key Pair Authentication** utilizes RSA key pairs for authentication. Users generate a public-private key pair, register the public key with Snowflake, and use the private key to authenticate. This method is commonly used for service accounts and programmatic access through connectors and drivers.

**Single Sign-On (SSO)** allows users to authenticate through an external identity provider using SAML 2.0 or OAuth. This enables organizations to leverage existing identity management systems like Okta, Azure AD, or ADFS. SSO provides centralized user management and simplified access control.

**Federated Authentication** extends SSO capabilities, allowing seamless integration with enterprise identity solutions. This reduces password fatigue and improves security posture.

**OAuth** enables third-party applications to access Snowflake on behalf of users through secure token-based authentication. This is particularly useful for programmatic integrations.

Administrators can configure network policies to restrict access based on IP addresses, adding another security dimension. Understanding these authentication methods helps organizations implement appropriate security measures based on their requirements and compliance needs.

Multi-factor authentication (MFA)

Multi-factor authentication (MFA) is a critical security feature in Snowflake that adds an extra layer of protection to user accounts beyond traditional username and password combinations. MFA requires users to provide two or more verification factors to gain access to their Snowflake account, significantly reducing the risk of unauthorized access even if credentials are compromised.

In Snowflake, MFA is powered by the Duo Security service, which is integrated into the platform. When MFA is enabled, users must authenticate using something they know (their password) combined with something they have (typically a mobile device running the Duo Mobile app). This two-factor approach ensures that stolen passwords alone cannot grant access to sensitive data.

Snowflake supports MFA enrollment at the user level, and account administrators can enforce MFA requirements for specific users or roles. Users can self-enroll in MFA through the Snowflake web interface, where they scan a QR code with the Duo Mobile app to link their device. Once enrolled, each login attempt requires approval through a push notification, a passcode generated by the app, or a phone callback.

Key considerations for MFA in Snowflake include: Account administrators with the ACCOUNTADMIN role should always have MFA enabled as a best practice. MFA can be required for all users through security policies. The feature works with both the Snowflake web interface and SnowSQL command-line client. Service accounts and programmatic access may use alternative authentication methods like key pair authentication instead of MFA.

For the SnowPro Core Certification, understanding MFA implementation, enrollment processes, and best practices is essential. Organizations should establish clear policies regarding MFA enforcement, especially for privileged accounts and users accessing sensitive data. MFA represents a fundamental component of Snowflakes defense-in-depth security strategy, helping organizations meet compliance requirements and protect their data assets from credential-based attacks.

Single sign-on (SSO) with SAML

Single Sign-On (SSO) with SAML (Security Assertion Markup Language) is a crucial authentication mechanism in Snowflake that enables users to access their Snowflake accounts using their organization's identity provider credentials. SAML is an XML-based open standard for exchanging authentication and authorization data between parties.

In Snowflake's SSO implementation, SAML 2.0 serves as the protocol that facilitates secure communication between the Identity Provider (IdP) and Snowflake (the Service Provider). When users attempt to log into Snowflake, they are redirected to their organization's IdP for authentication. Once authenticated, the IdP sends a SAML assertion back to Snowflake, confirming the user's identity.

Key components of SSO with SAML in Snowflake include:

1. Identity Provider (IdP): The system that manages user identities and performs authentication. Common IdPs include Okta, Azure AD, ADFS, and OneLogin.

2. Service Provider (SP): In this case, Snowflake acts as the SP that receives and validates SAML assertions.

3. SAML Assertion: An XML document containing user authentication information passed from the IdP to Snowflake.

To configure SSO in Snowflake, administrators must set up a security integration using the CREATE SECURITY INTEGRATION command, specifying SAML2 as the type. Required parameters include the IdP's SSO URL, certificate, and entity ID.

Benefits of using SSO with SAML in Snowflake include enhanced security through centralized authentication, reduced password fatigue for users, simplified user management, and compliance with organizational security policies.

Snowflake supports both IdP-initiated and SP-initiated SSO flows. In IdP-initiated SSO, users start from the identity provider portal. In SP-initiated SSO, users begin at Snowflake's login page and are then redirected to the IdP.

Administrators can also configure federated authentication to work alongside native Snowflake authentication, providing flexibility in how users access the platform.

Key pair authentication

Key pair authentication in Snowflake is a robust security mechanism that provides an alternative to traditional username and password authentication. This method utilizes asymmetric cryptography, consisting of a public key and a private key pair, to authenticate users and service accounts accessing Snowflake.

The authentication process works as follows: First, you generate a key pair using tools like OpenSSL. The private key remains securely stored on the client side and should never be shared, while the public key is assigned to the Snowflake user account using the ALTER USER command with the RSA_PUBLIC_KEY parameter.

When a connection attempt occurs, the client uses the private key to sign a challenge from Snowflake. The server then verifies this signature using the stored public key. If verification succeeds, access is granted. This eliminates the need to transmit passwords over the network, significantly enhancing security.

Key pair authentication is particularly valuable for automated processes, programmatic access, and service accounts where storing passwords in scripts poses security risks. It supports connections through the Snowflake JDBC driver, ODBC driver, Python connector, and other client interfaces.

Snowflake allows users to have up to two active public keys simultaneously, enabling key rotation with zero downtime. Administrators can use RSA_PUBLIC_KEY and RSA_PUBLIC_KEY_2 parameters to manage this rotation process smoothly.

Best practices include protecting private keys with strong passphrases, storing them in secure locations with restricted access permissions, and implementing regular key rotation schedules. Organizations should also maintain proper key management procedures and revoke compromised keys promptly.

The DESCRIBE USER command allows administrators to view configured public keys, while the RSA_PUBLIC_KEY_FP and RSA_PUBLIC_KEY_2_FP parameters display key fingerprints for verification purposes. This authentication method aligns with enterprise security standards and compliance requirements, making it essential for production Snowflake deployments.

OAuth integration

OAuth integration in Snowflake provides a secure and standardized method for authenticating users and applications without exposing credentials. OAuth (Open Authorization) is an industry-standard protocol that enables third-party applications to obtain limited access to Snowflake resources on behalf of users.

In Snowflake, OAuth integration supports two primary flows: External OAuth and Snowflake OAuth. External OAuth allows organizations to use their existing identity providers such as Okta, Azure AD, or custom OAuth servers to authenticate users. Snowflake OAuth is a built-in option where Snowflake acts as both the authorization and resource server.

To configure OAuth integration, administrators create a security integration object using the CREATE SECURITY INTEGRATION command. This integration defines the OAuth provider settings, including client credentials, token endpoints, and scope mappings. The integration maps OAuth tokens to Snowflake roles, controlling what resources authenticated users can access.

Key benefits of OAuth integration include enhanced security through token-based authentication, elimination of password management overhead, and seamless single sign-on (SSO) experiences for users. Tokens have limited lifespans and can be revoked, reducing the risk associated with compromised credentials.

For programmatic access, applications receive access tokens after successful authentication with the identity provider. These tokens are then presented to Snowflake when establishing connections. Snowflake validates the token against the configured security integration and grants access based on the mapped roles.

Administrators can monitor OAuth usage through the LOGIN_HISTORY view, which tracks authentication attempts and methods. They can also configure token validity periods and refresh token policies to balance security with user convenience.

OAuth integration is particularly valuable for organizations with existing identity management infrastructure, enabling centralized access control and audit capabilities while maintaining Snowflakes robust security model. It supports modern application architectures and facilitates secure API-based interactions with Snowflake resources.

Network policies

Network policies in Snowflake are a crucial security feature that allows administrators to control which IP addresses can access their Snowflake account. This functionality helps organizations restrict access to trusted network locations and enhance their overall security posture.

Network policies work by defining allowed and blocked IP address ranges using CIDR notation. When configured, Snowflake evaluates incoming connection requests against these policies before granting access. If a user attempts to connect from an IP address that falls outside the allowed ranges or within blocked ranges, the connection is denied.

There are two levels at which network policies can be applied: account level and user level. Account-level network policies apply to all users within the Snowflake account, establishing a baseline security boundary. User-level network policies can be assigned to individual users, providing more granular control when specific users require different access restrictions.

To create a network policy, administrators use the CREATE NETWORK POLICY command, specifying ALLOWED_IP_LIST and optionally BLOCKED_IP_LIST parameters. The blocked list takes precedence over the allowed list, enabling administrators to allow a broad range while excluding specific addresses.

Only users with the SECURITYADMIN role or higher, or those with the CREATE NETWORK POLICY privilege, can create and manage network policies. The ACCOUNTADMIN role is required to activate a network policy at the account level using ALTER ACCOUNT SET NETWORK_POLICY.

Important considerations include ensuring that administrators do not accidentally lock themselves out by misconfiguring IP ranges. Snowflake recommends testing policies thoroughly before activation. Additionally, network policies support both IPv4 addresses and can be modified or dropped as organizational requirements change.

Network policies complement other Snowflake security features such as multi-factor authentication, SSO integration, and role-based access control, forming a comprehensive defense strategy for protecting sensitive data within your Snowflake environment.

Private connectivity (AWS PrivateLink, Azure Private Link)

Private connectivity in Snowflake refers to secure, dedicated network connections between your cloud infrastructure and Snowflake services, bypassing the public internet entirely. This is achieved through AWS PrivateLink and Azure Private Link, depending on your cloud provider.

AWS PrivateLink enables private connectivity between your AWS Virtual Private Cloud (VPC) and Snowflake. When configured, traffic between your applications and Snowflake travels through Amazon's internal network rather than traversing the public internet. This significantly enhances security by reducing exposure to potential threats and ensuring data remains within the AWS network backbone.

Azure Private Link provides similar functionality for Microsoft Azure environments. It creates a private endpoint within your Azure Virtual Network (VNet) that connects to Snowflake services. All communication occurs over Microsoft's private network infrastructure, maintaining data privacy and compliance requirements.

Key benefits of private connectivity include:

1. Enhanced Security: Data never traverses the public internet, eliminating exposure to external threats and man-in-the-middle attacks.

2. Simplified Network Architecture: You can access Snowflake using private IP addresses, removing the need for complex firewall rules or VPN configurations.

3. Compliance: Many regulatory frameworks require private network connections for sensitive data. Private Link helps meet these requirements.

4. Reduced Latency: Traffic routing through cloud provider backbones often results in more consistent and potentially faster connections.

To implement private connectivity, Snowflake accounts must be on Business Critical edition or higher. The setup involves creating private endpoints in your cloud environment and configuring Snowflake to accept connections through these endpoints. Network policies can then restrict access to only allow connections from specific private endpoints.

For the SnowPro Core exam, understand that private connectivity is an account-level security feature that provides network isolation, requires specific Snowflake editions, and integrates with cloud provider networking services to establish secure communication channels.

Data encryption at rest and in transit

Data encryption is a fundamental security feature in Snowflake that protects sensitive information both at rest and in transit. Understanding these concepts is essential for the SnowPro Core Certification.

**Encryption at Rest:**
Snowflake automatically encrypts all data stored in its platform using AES-256 strong encryption. This includes all table data, temporary data, and cached query results. The encryption happens transparently with no performance impact or additional configuration required from users. Snowflake employs a hierarchical key model where encryption keys are managed through a key hierarchy. The platform uses a combination of account-level keys, table-level keys, and file-level keys. For organizations requiring additional control, Snowflake offers Tri-Secret Secure, which combines a Snowflake-maintained key with a customer-managed key stored in a cloud provider's key management service (like AWS KMS, Azure Key Vault, or Google Cloud KMS). This ensures that data cannot be decrypted by Snowflake alone.

**Encryption in Transit:**
All data transmitted to and from Snowflake is encrypted using TLS (Transport Layer Security) 1.2 or higher. This applies to all communication channels including client connections, data loading operations, and internal data transfers between Snowflake components. HTTPS is enforced for all web-based access, and secure connections are mandatory for all client drivers and connectors.

**Key Management:**
Snowflake handles automatic key rotation periodically, typically every 30 days for active keys. Re-keying of encrypted data occurs annually. Customers on Business Critical edition and higher can enable periodic re-encryption of their data.

**Compliance Benefits:**
These encryption mechanisms help organizations meet regulatory requirements such as HIPAA, PCI-DSS, SOC 2, and GDPR. The combination of encryption at rest and in transit ensures comprehensive data protection throughout the entire data lifecycle within the Snowflake environment.

Tri-Secret Secure encryption

Tri-Secret Secure is Snowflake's most advanced encryption option, providing an additional layer of security for organizations with stringent data protection requirements. This feature combines Snowflake-managed keys with customer-managed keys to create a composite master key, offering enhanced control over data encryption.

In standard Snowflake encryption, data is protected using AES-256 encryption with keys managed entirely by Snowflake through a hierarchical key model. Tri-Secret Secure extends this by incorporating a customer-managed key (CMK) stored in a cloud provider's key management service, such as AWS KMS, Azure Key Vault, or Google Cloud KMS.

The composite master key is created by combining the Snowflake-managed key with the customer-managed key. Both keys are required to decrypt data, meaning neither Snowflake nor the customer can access the data independently. This dual-key approach ensures that customers maintain ultimate control over their encrypted data.

Key benefits of Tri-Secret Secure include enhanced data sovereignty, regulatory compliance support, and the ability to revoke access to data by disabling the customer-managed key. If an organization needs to terminate access to their Snowflake data, they can simply disable their CMK, rendering all data inaccessible.

To implement Tri-Secret Secure, organizations must work with Snowflake to configure the integration between their cloud provider's key management service and their Snowflake account. This requires Business Critical Edition or higher.

The encryption hierarchy in Tri-Secret Secure follows Snowflake's standard model: file keys encrypt individual data files, table keys wrap file keys, account keys wrap table keys, and the composite master key protects the entire hierarchy.

Tri-Secret Secure is particularly valuable for industries handling sensitive data, including healthcare, financial services, and government sectors, where maintaining exclusive control over encryption keys is a regulatory or organizational requirement.

Account usage views and monitoring

Account usage views and monitoring in Snowflake provide comprehensive visibility into your account's activities, resource consumption, and security posture. These features are essential for administrators managing Snowflake environments and are important topics for the SnowPro Core Certification.

Snowflake offers the ACCOUNT_USAGE schema within the SNOWFLAKE database, which contains views that store historical data about account activity for up to one year. This differs from the INFORMATION_SCHEMA, which provides real-time data but with shorter retention periods.

Key account usage views include:

1. LOGIN_HISTORY - Tracks all login attempts, both successful and failed, helping identify potential security threats or unauthorized access attempts.

2. QUERY_HISTORY - Records all queries executed in the account, including execution time, data scanned, and user information.

3. WAREHOUSE_METERING_HISTORY - Shows credit consumption by virtual warehouses, enabling cost management and optimization.

4. STORAGE_USAGE - Monitors data storage consumption over time.

5. ACCESS_HISTORY - Tracks which users accessed specific data objects, supporting audit and compliance requirements.

6. SESSIONS - Provides details about user sessions including authentication methods used.

For security monitoring, administrators should regularly review:

- Failed login attempts to detect brute force attacks
- Unusual query patterns that might indicate data exfiltration
- Changes to user privileges and role assignments
- Network policy modifications

Access to ACCOUNT_USAGE views requires the ACCOUNTADMIN role or specific privileges granted through IMPORTED PRIVILEGES on the SNOWFLAKE database.

Best practices for monitoring include setting up alerts for suspicious activities, creating dashboards for ongoing visibility, and establishing regular audit reviews. Organizations can also integrate Snowflake monitoring data with external SIEM tools for comprehensive security management.

Understanding these monitoring capabilities helps organizations maintain security compliance, optimize costs, and troubleshoot performance issues effectively within their Snowflake environment.

Access history and auditing

Access history and auditing in Snowflake represents a comprehensive security framework that enables organizations to monitor, track, and analyze all activities occurring within their Snowflake environment. This functionality is essential for maintaining compliance, detecting potential security threats, and understanding user behavior patterns.

Snowflake provides several key features for access history and auditing. The ACCOUNT_USAGE schema contains views that store historical data about account activities for up to one year. Key views include ACCESS_HISTORY, which tracks all data access operations including SELECT statements and data manipulation activities. This view captures what data was accessed, who accessed it, and when the access occurred.

The QUERY_HISTORY view maintains records of all queries executed within the account, including execution time, warehouse used, and query status. This helps administrators identify performance issues and unusual query patterns that might indicate security concerns.

LOGIN_HISTORY tracks all authentication attempts, both successful and failed, providing visibility into potential unauthorized access attempts. This is crucial for identifying brute force attacks or compromised credentials.

SESSION_HISTORY provides details about user sessions, including connection information and session duration, helping track user activity patterns.

For real-time monitoring, the INFORMATION_SCHEMA provides similar views but with a shorter retention period of seven days to two weeks, depending on the specific view.

Snowflake also supports integration with external SIEM (Security Information and Event Management) tools through data sharing and export capabilities, allowing organizations to correlate Snowflake activities with other enterprise security events.

Role-based access control ensures that only authorized personnel can view audit information. The ACCOUNTADMIN role typically has full access to these monitoring capabilities, while custom roles can be configured for security teams requiring limited audit access.

These auditing capabilities help organizations meet regulatory requirements such as GDPR, HIPAA, and SOC 2 compliance standards.

Session policies

Session policies in Snowflake are a critical security feature that allows administrators to control and manage user session behavior within the platform. These policies help organizations maintain security standards by defining how long users can remain connected and when they need to re-authenticate.

A session policy specifies the idle timeout period for user sessions. When a user remains inactive for longer than the specified duration, Snowflake automatically terminates their session, requiring them to log in again. This helps prevent unauthorized access from unattended workstations or forgotten sessions.

Session policies can be applied at two levels: account level and user level. When set at the account level, the policy affects all users unless a more specific user-level policy overrides it. User-level policies take precedence over account-level policies, allowing administrators to customize timeout settings for specific users based on their roles or security requirements.

Key parameters in session policies include SESSION_IDLE_TIMEOUT_MINS, which defines the number of minutes a session can remain idle before automatic termination. The default value is 240 minutes (4 hours), but organizations can adjust this based on their security needs.

To create a session policy, administrators use the CREATE SESSION POLICY command. They can then apply the policy using ALTER ACCOUNT or ALTER USER commands. Only users with appropriate privileges, such as SECURITYADMIN or ACCOUNTADMIN roles, can create and manage session policies.

Session policies work alongside other security features like network policies, multi-factor authentication, and password policies to provide comprehensive access control. Organizations in regulated industries often configure shorter timeout periods to comply with security frameworks and audit requirements.

Best practices include setting reasonable timeout values that balance security with user convenience, applying stricter policies to privileged accounts, and regularly reviewing session policy configurations as part of overall security governance.

More Account Access and Security questions
510 questions (total)