Courseiva
Utilize Vault CLI and APIeasyMultiple ChoiceObjective-mapped

VA-003 Utilize Vault CLI and API Practice Question

A user wants to log in using the userpass auth method with username 'jdoe' and password 'p@ssw0rd'. What is the correct API endpoint and request?

⚠ Common exam trap

HashiCorp often tests the misconception that authentication requests can use GET or PUT methods or pass credentials in headers or query parameters, when Vault strictly requires POST with a JSON body for login endpoints.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

POST /v1/auth/userpass/login/jdoe with JSON body {"password":"p@ssw0rd"}

The userpass auth method in Vault requires a POST request to the login endpoint with the password provided in the JSON body. Option D correctly uses POST /v1/auth/userpass/login/jdoe with {"password":"p@ssw0rd"}, which matches the Vault API specification for authenticating against a userpass backend.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • GET /v1/auth/userpass/login/jdoe with header "password: p@ssw0rd"

    Why it's wrong here

    Incorrect; login requires POST and password in body.

  • PUT /v1/auth/userpass/login/jdoe with JSON body {"password":"p@ssw0rd"}

    Why it's wrong here

    Incorrect; login endpoint uses POST, not PUT.

  • POST /v1/auth/userpass/login/jdoe?password=p@ssw0rd

    Why it's wrong here

    Incorrect; password should be in request body, not query parameter.

  • POST /v1/auth/userpass/login/jdoe with JSON body {"password":"p@ssw0rd"}

    Why this is correct

    Correct; standard userpass login API call.

About these practice questions

This VA-003 question is part of Courseiva's 498-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This VA-003 practice question is part of Courseiva's free HashiCorp certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the VA-003 exam.