Knowledge Management

Delete Specific Key from KVSTORE

scoughlin1
Path Finder

I am using the Mimecast v3.1.1 App/Addon and Ia m am trying to delete a specific key the application inserts into the KVSTORE.

The problem I am having is that the key is a pipe delimited series of values have have been URL encoded.

I created my own entry allowing the KVSTORE to create the key for me and deleted it successfully using a curl command, but I cannot use the same command to delete the URL encoded key.

This was successful
curl -k -u admin: -X DELETE https://x.x.x.x:8089/servicesNS/nobody/TA-mimecast-for-splunk/storage/collections/data/TA_mimecast_f...

This failed
curl -k -u admin: -X DELETE https://x.x.x.x:8089/servicesNS/nobody/TA-mimecast-for-splunk/storage/collections/data/TA_mimecast_f...

The error I receive is object not found. The actual key value was copy and pasted from the output of this command:

curl -k -u admin: https://127.0.0.1:8089/servicesNS/nobody/TA-mimecast-for-splunk/storage/collections/data/TA_mimecast...

0 Karma

scoughlin1
Path Finder

Update:

The "failed" command in my above post should have worked. Although I tried it several times before posting here, today it worked.

In my failed example is a double URL coded string. That is exactly how it should look when trying to delete the key. When I re-ran the command to output the key again I notice the key value it output was NOT double encoded.

The single encoded string looked like this:

myvalue_ttp%7Cttp-url%7Chttps%3A%2F%2Fus-api.mimecast.com%7CCUSX1X11

Which I then URL encoded to:

myvalue_ttp%257Cttp-url%257Chttps%253A%252F%252Fus-api.mimecast.com%257CCUSX1X11

Hopefully if any of you run into this problem you can at least see the process I used and hopefully it will work for you the first time!

Get Updates on the Splunk Community!

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...

Let’s Get You Certified – Vegas-Style at .conf24

Are you ready to level up your Splunk game? Then, let’s get you certified live at .conf24 – our annual user ...