Skip to content

Commit

Permalink
Merge pull request #159 from knownsec/seebug_api_update
Browse files Browse the repository at this point in the history
update seebug api for fetch PoC for pocsuite 2.x
  • Loading branch information
Hysia authored Dec 10, 2018
2 parents ae8cad3 + a9e8584 commit 2c85b77
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pocsuite/api/x.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,19 +117,19 @@ def newToken(self):
return False

def static(self):
req = requests.get('https://www.seebug.org/api/user/poc_list', headers=self.headers)
req = requests.get('https://www.seebug.org/api/user/poc_list?framework=2', headers=self.headers)
self.stats = ast.literal_eval(req.content)
if 'detail' in self.stats:
return False
return 'According to record total %s PoC purchased' % len(self.stats)

def seek(self, keyword):
req = requests.get('https://www.seebug.org/api/user/poc_list?q=%s' % keyword, headers=self.headers, )
req = requests.get('https://www.seebug.org/api/user/poc_list?framework=2&q=%s' % keyword, headers=self.headers, )
self.pocs = ast.literal_eval(req.content)
return '%s purchased poc related to keyword "%s"' % (len(self.pocs), keyword)

def retrieve(self, ID):
req = requests.get('https://www.seebug.org/api/user/poc_detail?id=%s' % ID, headers=self.headers, )
req = requests.get('https://www.seebug.org/api/user/poc_detail?framework=2&id=%s' % ID, headers=self.headers, )
try:
ret = ast.literal_eval(req.content)
except:
Expand Down

0 comments on commit 2c85b77

Please sign in to comment.