mirror of
https://github.com/adulau/pdns-qof-server.git
synced 2024-12-22 08:45:57 +00:00
fquery added to include rdata pivot to ease query search
This commit is contained in:
parent
24239a12a5
commit
5623b1b06f
1 changed files with 11 additions and 0 deletions
|
@ -106,8 +106,19 @@ class QueryHandler(tornado.web.RequestHandler):
|
|||
else:
|
||||
self.write(JsonQOF(getRecord(t = q.strip())))
|
||||
|
||||
class FullQueryHandler(tornado.web.RequestHandler):
|
||||
def get(self, q):
|
||||
print ("fquery: "+q)
|
||||
if iptools.ipv4.validate_ip(q) or iptools.ipv6.validate_ip(q):
|
||||
for x in getAssociatedRecords(q):
|
||||
self.write(JsonQOF(getRecord(x)))
|
||||
else:
|
||||
for x in getAssociatedRecords(q):
|
||||
self.write(JsonQOF(getRecord(t = x.strip())))
|
||||
|
||||
application = tornado.web.Application([
|
||||
(r"/query/(.*)",QueryHandler),
|
||||
(r"/fquery/(.*)",FullQueryHandler),
|
||||
(r"/info", InfoHandler)
|
||||
])
|
||||
|
||||
|
|
Loading…
Reference in a new issue