HTTP LIST verb not supported by REST clients

31 views
Skip to first unread message

bde...@navelplace.com

unread,
Aug 13, 2018, 11:54:22 AM8/13/18
to Vault
Sorry if this is old territory, but I couldn't find this mentioned as a git issue or here on the list.

REST clients like Spring's RestTemplate don't support the verb "LIST" because it's not part of the HTTP standard. Is there a workaround for this to avoid having to manually implement a REST call to call those LIST methods? It seems that they don't respond to calling GET on the same URL. (At least this is the behavior I see for /transit/keys)

Jim Kalafut

unread,
Aug 13, 2018, 12:55:00 PM8/13/18
to Vault
Hi, 

In lieu of LIST you can add list=true as a query parameter to GET.  See: https://www.vaultproject.io/api/index.html#reading-writing-and-listing-secrets

Regards,
Jim

Jeff Mitchell

unread,
Aug 14, 2018, 9:52:46 AM8/14/18
to Vault
Hi,

I would also suggest filing a ticket with Spring. RFC 7231 defines specific well-known HTTP verbs with standardized semantics, but any verb is valid, whether registered with IANA or not. Most languages/clients ask you to specify the verb you want rather than forcing you to choose from a predefined set for this exact reason, e.g. https://golang.org/pkg/net/http/#NewRequest

Best,
Jeff

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/hashicorp/vault/issues
IRC: #vault-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Vault" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vault-tool+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vault-tool/54511b25-3782-487e-b8ed-72d93e3e41fb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages