icon/x Created with Sketch.

Splunk Cookie Policy

We use our own and third-party cookies to provide you with a great online experience. We also use these cookies to improve our products and services, support our marketing campaigns, and advertise to you on our website and other websites. Some cookies may continue to collect information after you have left our website. Learn more (including how to update your settings) here.
Accept Cookie Policy

Accept License Agreements

This app is provided by a third party and your right to use the app is in accordance with the license provided by that third-party licensor. Splunk is not responsible for any third-party apps and does not provide any warranty or support. If you have any questions, complaints or claims with respect to this app, please contact the licensor directly.

Thank You

Downloading Webtools Add-on
SHA256 checksum (webtools-add-on_124.tgz) 16e786985c56f776c3773e6dae22e4178892b7163b968a6b10c02b54413d8174 SHA256 checksum (webtools-add-on_123.tgz) fdbe768fcff43e6c5e89bb8a19a3b60d5acfa18a6a246b7ec9a29d7d68d98437 SHA256 checksum (webtools-add-on_122.tgz) 19a255a5b4244f40f5b6bb48198c9dd72b2bdc059a39e01af5e9afcb2ce63142 SHA256 checksum (webtools-add-on_120.tgz) 3422e2754de66109ec276619ec4dfa15a2c51c3dc7eb92d5b40f6c84c5f07205 SHA256 checksum (webtools-add-on_110.tgz) 8986061e7d61e18fb99d9956481f267f47d8058b477c5fb56e721101c5c3f104 SHA256 checksum (webtools-add-on_100.tgz) 885b98703b9b6dedecda392aa617bb568523796253409c4eedda00feb203d0cf
To install your download
For instructions specific to your download, click the Details tab after closing this window.

Flag As Inappropriate

Webtools Add-on

Splunk AppInspect Passed
Overview
Details
This app is intended to solve the problem of connecting to external APIs/REST with Splunk Search. It allows you to use CURL inline with your other SPL and to URLENCODE as needed too. In addition, you can use TESTPORT to check if TCP ports are open. Finally, we added the ability to use CURL and TESTPORT as modular inputs. Making this app, your one stop shop for monitoring your web tools

IF YOU LIKE THIS APP, PLEASE LEAVE A RATING... TIA!!!

Please email me michael.bentley at stage2sec.com if you have any issues. I actively support my apps and am anxious to receive any feedback.
-JKat54

IF YOU LIKE THIS APP, PLEASE LEAVE A RATING... TIA!!! Please email me michael.bentley AT stage2sec.com if you have any issues. I actively support my apps and am anxious to receive any feedback. -JKat54

Install Instructions:

Install app, restart splunk, profit!

curl command:

Syntax:

[optional:<generating_search>] | curl uri=<uri> [optional: method=<get|post|delete> verifyssl=<true|false> datafield=<field_name> data=<data> headerfield=<json_header_field_name> user=<user> pass=<password> debug=<true|false> splunkauth=<true|false> timeout=<float>]

Examples:

  • GET data from uri, specifing user, pass, and very short timeout:
    | curl method=get uri=https://localhost:8089/services/admin user=admin pass=changeme timeout=0.001 | table curl*

  • GET data from uri, passing existing session key:
    | curl method=get uri=https://localhost:8089/services/admin splunkauth=true | table curl*

  • POST data to uri, specifying data="{\"name\":\"Test\",\"value\":\"Hello World\",\"severity\":\"warn\"}":
    | makeresults count=1
    | eval data="{\"name\":\"Test\",\"value\":\"Hello World\",\"severity\":\"warn\"}"
    | curl method=post uri=https://localhost:8089/services/messages/new splunkauth=true debug=true datafield=data
    | table curl*

  • POST data to uri, using a data field that exists in the Splunk search pipeline:
    | makeresults count=1
    | eval message="{\"name\":\"restart_link\",\"value\":\"Hello World\",\"severity\":\"warn\"}"
    | curl method=post uri=https://localhost:8089/services/messages/new datafield=message splunkauth=true
    | table curl*

  • Deleting fired alerts for search named "Test Alert":
    | rest /servicesNS/admin/search/alerts/fired_alerts/Test%20Alert
    | fields title
    | head 10
    | map search="
    | curl method=delete uri="https://localhost:8089/servicesNS/admin/search/alerts/fired_alerts/$title$" user=admin pass=changeme
    | table *
    "

  • Getting search results from google:
    | curl method=get verifyssl=True uri=https://google.com/search?q=splunk debug=t

  • Getting multiple search results from google using data in the pipe:
    | makeresults count=2
    | eval data="q=".random()
    | curl method=get verifyssl=false uri="https://google.com/search" datafield=data debug=true

  • Setting a Custom Header & Test Data:
    | makeresults count=1
    | eval header="{\"content-type\":\"application/json\"}"
    | eval data="{\"test data\":\"DATA\"}"
    | curl method=post uri=https://localhost:8089/services user=admin pass=changeme debug=true headerfield=header datafield=data

testport command:

UDP has been removed in version 1.2.4 due to failure to pass app inspect

Syntax:

| testport protocol=<tcp|udp> address=<ip> port=<port> [ Optional: count=<number_of_tests> timeout=<timeout_in_seconds> ]

Examples:

  • Testing if port 8000 is open on localhost
    | testport protocol=tcp address=127.0.0.1 port=8000 count=5 timeout=2

  • Send 100 UDP test messages to localhost on port 514
    | testport protocol=udp address=127.0.0.1 port=514 count=100

urlencode command:

Syntax:

<generating_search> | urlencode <field_1> <field_2> <field_n> ... | table <field_1> <field_2> <field_n> ...

Release Notes

Version 1.2.4
Aug. 2, 2019

Version 1.2.4:
- Removed UDP functionalities to pass new appinspect rules
- Fixed "bad operand" issue reported here: https://answers.splunk.com/answers/738867/web-tools-add-on-ta-webtools-curl-command-throws-a.html - Thanks @suser2019
- Cleaned up streaming logic

Version 1.2.3
Jan. 28, 2019

Release Version 1.2.3:
- Added HEAD method
- Changed GET method to use query parameters instead of data payloads
- Added curl_response_url to debug output

Version 1.2.2
Jan. 24, 2019

Release Version 1.2.2:
- Fixed bug in curl.py (curl spl command) that forced empty authentication parameters when authentication isnt required
- Thanks to @runner724 for reporting via answers - https://answers.splunk.com/answers/716585/webtools-app-how-to-make-get-without-basic-authent.html)

Version 1.2.0
Dec. 28, 2018

Release Version 1.2.0:
- Code readability improvements in curl.py
- Added 'timeout' option to curl command (as per request)
- Added exception handling to request functions in curl.py to support 'timeout' option

Version 1.1.0
Dec. 28, 2018

Release Version 1.1.0
- Made http method default to GET if not specified
- Added custom header capability to streaming curl command (by popular demand)
- Added curl_header to debug output of streaming curl command (by popular demand)
- Added curl_splunkauth to debug output of streaming & generating curl commands
- Added custom header capability to curl modular inputs (by popular demand)

Version 1.0.0
Aug. 24, 2018

Initial Release v1.0.0
- This was previously known as Splunk-TA_webtools, now it's been renamed to TA-webtools
- Now supports scripted inputs with the curl command
- Also added testport command for testing if TCP ports are open, and sending test UDP data for UDP tests

155
Installs
623
Downloads
Share Subscribe LOGIN TO DOWNLOAD

Subscribe Share

AppInspect Tooling

Splunk AppInspect evaluates Splunk apps against a set of Splunk-defined criteria to assess the validity and security of an app package and components.

Are you a developer?

As a Splunkbase app developer, you will have access to all Splunk development resources and receive a 50GB license to build an app that will help solve use cases for customers all over the world. Splunkbase has 1000+ apps and add-ons from Splunk, our partners and our community. Find an app or add-on for most any data source and user need, or simply create your own with help from our developer portal.

Follow Us:
© 2005-2019 Splunk Inc. All rights reserved.
Splunk®, Splunk>®, Listen to Your Data®, The Engine for Machine Data®, Hunk®, Splunk Cloud™, Splunk Light™, SPL™ and Splunk MINT™ are trademarks and registered trademarks of Splunk Inc. in the United States and other countries. All other brand names, product names, or trademarks belong to their respective owners.