vbobrov / pxgrid-api Goto Github PK
View Code? Open in Web Editor NEWpxGrid Python Library and CLI utility to interact with Cisco ISE pxGrid services
License: Apache License 2.0
pxGrid Python Library and CLI utility to interact with Cisco ISE pxGrid services
License: Apache License 2.0
Hello,
I am trying to use PXAPI to assign an ANC policy to a mac address with ISE 3.1p5. Everytime I invoke this method I get a NullException in ISE pxGrid logs, and an error 500 in PXAPI:
Traceback (most recent call last):
File "C:\dev\python\ISE\pxgrid\testpx.py", line 10, in
print(api.anc_apply_endpoint_by_mac_address("Quarantine","AA:AA:AA:AA:AA:AA"))
File "C:\dev\env\lib\site-packages\pxapi\pxapi.py", line 403, in anc_apply_endpoint_by_mac_address
return(self.__send_px_api(self.SERVICE_ANC,"applyEndpointByMacAddress",{"policyName":policy,"mac":mac}))
File "C:\dev\env\lib\site-packages\pxapi\pxapi.py", line 159, in __send_px_api
raise Exception(f"API {api} to service {service} failed with code {response.status_code}. Content: {response.text}")
Exception: API applyEndpointByMacAddress to service com.cisco.ise.config.anc failed with code 500. Content: {"message":"java.lang.NullPointerException"}
And in ISE logs:
2023-05-24 08:00:23,777 ERROR [Thread-16][] cisco.cpm.pxgridwebapp.config.RestExceptionHandler -:::::- HTTP API request=uri=/pxgrid/ise/config/anc/applyEndpointByMacAddress;client=10.21.123.243;user=testclient
java.lang.NullPointerException
at com.cisco.ise.anc.utils.MACAddress.validateMac(MACAddress.java:84)
at com.cisco.ise.anc.operation.EndpointOperationManager.performSessionLookup(EndpointOperationManager.java:247)
at com.cisco.ise.anc.operation.EndpointOperationManager.performWithPolicyUpdate(EndpointOperationManager.java:209)
at com.cisco.ise.anc.operation.EndpointOperationManager.performApplyPolicyAndNoWait(EndpointOperationManager.java:99)
at com.cisco.cpm.pxgridwebapp.ise.rest.AncREST.applyEndpointByMacAddress(AncREST.java:269)
at com.cisco.cpm.pxgridwebapp.ise.rest.AncREST$$FastClassBySpringCGLIB$$988ed386.invoke()
at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:779)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
at org.springframework.security.access.intercept.aopalliance.MethodSecurityInterceptor.invoke(MethodSecurityInterceptor.java:61)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:692)
at com.cisco.cpm.pxgridwebapp.ise.rest.AncREST$$EnhancerBySpringCGLIB$$697e9178.applyEndpointByMacAddress()
...etc...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.