File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/WebServiceCustomPolicy.py", line 154, in Severity
self._connection._update_web_service_custom_policy(Name=self._Name, Parameter='severity', Value=Severity)
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/MxConnection.py", line 934, in _update_web_service_custom_policy
return WebServiceCustomPolicy._update_web_service_custom_policy(connection=self, Name=Name, Parameter=Parameter, Value=Value)
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/WebServiceCustomPolicy.py", line 337, in _update_web_service_custom_policy
connection._mx_api('PUT', '/conf/webServiceCustomPolicies/%s' % Name, data=json.dumps(body))
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/MxConnection.py", line 257, in _mx_api
raise MxException("MX returned errors - %s" % str(error_message))
MxException: MX returned errors - [{'description': 'This is a predefined ADC item that cannot be changed', 'error-code': 'IMP-10146'}]
This is the DOCs example:
` MX Web Service Custom Policy Class
In reality, one gets:
`
pol = mx.get_web_service_custom_policy("Anti Google Hacking - 2")
pol Out[388]: <imperva_sdk 'WebServiceCustomPolicy' Object - 'Anti Google Hacking - 2'>
pol.Severity Out[389]: 'high'
pol.Severity = 'medium' Traceback (most recent call last):
File "", line 1, in
pol.Severity = 'medium'
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/WebServiceCustomPolicy.py", line 154, in Severity self._connection._update_web_service_custom_policy(Name=self._Name, Parameter='severity', Value=Severity)
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/MxConnection.py", line 934, in _update_web_service_custom_policy return WebServiceCustomPolicy._update_web_service_custom_policy(connection=self, Name=Name, Parameter=Parameter, Value=Value)
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/WebServiceCustomPolicy.py", line 337, in _update_web_service_custom_policy connection._mx_api('PUT', '/conf/webServiceCustomPolicies/%s' % Name, data=json.dumps(body))
File "/anaconda3/lib/python3.7/site-packages/imperva_sdk-0.2.0-py3.7.egg/imperva_sdk/MxConnection.py", line 257, in _mx_api raise MxException("MX returned errors - %s" % str(error_message))
MxException: MX returned errors - [{'description': 'This is a predefined ADC item that cannot be changed', 'error-code': 'IMP-10146'}]
`
Executed on latest release as of now.