Splunk® Machine Learning Toolkit

User Guide

This documentation does not apply to the most recent version of Splunk® Machine Learning Toolkit. For documentation on the most recent version, go to the latest release.

Algorithm permissions

In the Splunk Machine Learning Toolkit, you can define the read permissions for each algorithm. Read permissions dictate whether a user can access the algorithms. Administrators have write permissions by default. To change permission settings, either modify the REST API ACL endpoint in the algos.conf file, or modify the manual configuration of local.meta file.

Manage permissions in REST API

The example below uses the algorithm KMeans, although this process works the same way with any algorithm in the Splunk Machine Learning Toolkit.

  1. To change the algorithm settings, modify the API ACL endpoint in the algos.conf file.
    1. To assign read permissions to all roles:
      $ curl -k -u admin:<admin password> \
             https://localhost:8089/servicesNS/nobody/Splunk_ML_Toolkit/configs/conf-algos/KMeans/acl \
             -d owner=nobody \
             -d sharing=app \
             -d perms.read=*
      
    2. To assign read permissions to the user and power role:
      $ curl -k -u admin:<admin password> \
             https://localhost:8089/servicesNS/nobody/Splunk_ML_Toolkit/configs/conf-algos/KMeans/acl \
             -d owner=nobody \
             -d sharing=app \
             -d perms.read=user,power
      
  2. You do not need to restart splunkd after you change the permission settings in the REST API.

The read permission in the REST API also controls the GET method. If you are unfamiliar with the REST method subset, see HTTP Status Codes in the Rest API User Manual. For more information on ACL REST API endpoint, see Access Control list in the Rest API User Manual.

Manage permissions manually in the configuration file

You cannot modify the default.meta file directly. Instead, you can make changes in the local.meta file, and the new content will override the default.meta file. For further information on the structure of the default.meta file, see default.meta.conf in the Admin Manual.

The example below uses the algorithm KMeans, although this process works the same way with any algorithm in the Splunk Machine Learning Toolkit.

  1. If you do not have a local.meta file, create one.
  2. Open the local.meta file.
    $SPLUNK_HOME/etc/apps/Splunk_ML_Toolkit/metadata/local.meta
    
    1. To assign read permissions to all roles:
      [algos/KMeans]
      access = read : [ * ]
      
    2. To assign read permissions to the user and power roles:
      [algos/KMeans]
      access = read : [ user,power ] 
      
  3. Restart splunkd.

The process to change permissions in the REST API endpoint also changes the content of a local.meta file in the directory.

$SPLUNK_HOME/etc/apps/Splunk_ML_Toolkit/metadata
Last modified on 04 October, 2018
Import a machine learning algorithm from Splunkbase   Smart Forecasting Assistant

This documentation applies to the following versions of Splunk® Machine Learning Toolkit: 2.4.0, 3.0.0, 3.1.0, 3.2.0, 3.3.0, 3.4.0, 4.0.0, 4.1.0, 4.2.0, 4.3.0


Was this topic useful?







You must be logged into splunk.com in order to post comments. Log in now.

Please try to keep this discussion focused on the content covered in this documentation topic. If you have a more general question about Splunk functionality or are experiencing a difficulty with Splunk, consider posting a question to Splunkbase Answers.

0 out of 1000 Characters