
Answer-first summary for fast verification
Answer: ALTER USER jsmith SET RSA_PUBLIC_KEY='MIIBIjANBgkqh...';
The correct answer is D because Snowflake's key pair authentication requires assigning the public key to the user, not the private key. The private key remains securely stored on the client side and is never shared with Snowflake. The documentation clearly states that for key pair authentication, you use ALTER USER ... SET RSA_PUBLIC_KEY to assign the public key to the Snowflake user. Options A, B, and C are incorrect because they either reference non-existent parameters (RSA_P8_KEY, ENCRYPTED_KEY) or incorrectly suggest assigning the private key (RSA_PRIVATE_KEY), which would be a security risk and is not supported by Snowflake's authentication mechanism. The community discussion shows 100% consensus on answer D with references to official Snowflake documentation confirming this approach.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
Which command should be used to assign a private key to a Snowflake user for key pair authentication?
A
ALTER USER jsmith SET RSA_P8_KEY='MIIBIjANBgkqh...';
B
ALTER USER jsmith SET ENCRYPTED_KEY='MIIBIjANBgkqh...';
C
ALTER USER jsmith SET RSA_PRIVATE_KEY='MIIBIjANBgkqh...';
D
ALTER USER jsmith SET RSA_PUBLIC_KEY='MIIBIjANBgkqh...';