Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to get ACL permits/drops in pyaci #45

Open
the-modern-leo opened this issue Mar 4, 2020 · 2 comments
Open

Unable to get ACL permits/drops in pyaci #45

the-modern-leo opened this issue Mar 4, 2020 · 2 comments

Comments

@the-modern-leo
Copy link

the-modern-leo commented Mar 4, 2020

I have attempted to use all the solutions provided above for getting packets, and my query is returning an empty list.
result = apic.methods.ResolveClass('acllogPermitL3Pkt').GET() result2 = apic.mit.polUni().fvTenant(tenant).GET(**options.subtreeClass('acllogPermitL3Pkt')) result3 = apic.methods.ResolveClass('acllogPermitL3Pkt').GET(**options.filter( filters.Wcard('acllogDropL3Pkt.dn', f"ndbgs/acllog/tn-{tenant}") & filters.Wcard('acllogDropL3Pkt.srcIp', "10.71.0.164"))) test = apic.mit.polUni().fvTenant(tenant).GET()
Originally posted by @the-modern-leo in #44 (comment)

@the-modern-leo the-modern-leo changed the title Unable to get ACL drops in pyaci Unable to get ACL permits/drops in pyaci Mar 20, 2020
@the-modern-leo
Copy link
Author

Is there any progress on this issue?
The University of Utah is waiting for this to complete one of our tools.

@kprav33n
Copy link
Contributor

I just tried this with the first query that you pointed out on a local setup here.

python
Python 3.8.1 (default, Jan 17 2020, 15:05:28)
[GCC 9.2.1 20191008] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from pyaci import Node
>>> apic = Node('*****')
>>> apic.methods.Login('admin', '*****').POST()
<Response [200]>
>>> result = apic.methods.ResolveClass('acllogPermitL3Pkt').GET()
>>> len(result)
2400

There is no issue with PyACI. The query rightly returns results.

I suspect that you have not enabled the logging feature on your APIC. Can you please check your configuration. Please refer to the official documentation of APIC on how to enable this feature. Here is an instruction that says on how to do this for a new contract. For an existing contract, just follow step 11 alone.

https://www.cisco.com/c/en/us/td/docs/switches/datacenter/aci/apic/sw/4-x/security/b-Cisco-APIC-Security-Configuration-Guide-421/b-Cisco-APIC-Security-Configuration-Guide-421_chapter_01011.html#id_29992

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants