Skip to content
This repository was archived by the owner on Dec 23, 2020. It is now read-only.

上传 har 不成功 #5

Closed
ruby-ex opened this issue Oct 7, 2016 · 2 comments
Closed

上传 har 不成功 #5

ruby-ex opened this issue Oct 7, 2016 · 2 comments

Comments

@ruby-ex
Copy link

ruby-ex commented Oct 7, 2016

Charles : 4.0.1
导出的har文件

http://127.0.0.1:8000/ 上传没反应

在 python manage.py runserver 终端下为:

[07/Oct/2016 20:17:23] "GET /api-auth/login/?next=/ HTTP/1.1" 200 2662
[07/Oct/2016 20:17:38] "POST /api-auth/login/ HTTP/1.1" 302 0
[07/Oct/2016 20:17:38] "GET / HTTP/1.1" 200 399
[07/Oct/2016 20:17:40] "GET /api/tasks/stat/sqli HTTP/1.1" 200 2
Internal Server Error: /api/har/upload
Traceback (most recent call last):
  File "/ruby-ex/SQLiScanner/venv/lib/python3.5/site-packages/django/core/handlers/base.py", line 149, in get_response
    response = self.process_exception_by_middleware(e, request)
  File "/ruby-ex/SQLiScanner/venv/lib/python3.5/site-packages/django/core/handlers/base.py", line 147, in get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/ruby-ex/SQLiScanner/venv/lib/python3.5/site-packages/django/contrib/auth/decorators.py", line 23, in _wrapped_view
    return view_func(request, *args, **kwargs)
  File "/ruby-ex/SQLiScanner/venv/lib/python3.5/site-packages/django/views/decorators/csrf.py", line 58, in wrapped_view
    return view_func(*args, **kwargs)
  File "/ruby-ex/SQLiScanner/scanner/views.py", line 37, in addtaskbyhar
    handle_uploaded_file(request.FILES['file'], str(request.FILES['file']))
  File "/ruby-ex/SQLiScanner/scanner/views.py", line 49, in handle_uploaded_file
    parse_uploaded_file(filename)
  File "/ruby-ex/SQLiScanner/scanner/views.py", line 87, in parse_uploaded_file
    scan_options = handle_get_request_entrie(entrie, scan_options)
  File "/ruby-ex/SQLiScanner/scanner/views.py", line 104, in handle_get_request_entrie
    if '.' not in node and re.findall('(\d+)', node):
NameError: name 're' is not defined
[07/Oct/2016 20:17:54] "POST /api/har/upload HTTP/1.1" 500 16844

概览 里没显示有添加记录。

@ruby-ex
Copy link
Author

ruby-ex commented Oct 7, 2016

SQLiScanner/scanner/views.py

import re

就好了

@ruby-ex ruby-ex changed the title 上传har出错 上传 har 不成功 Oct 7, 2016
@ruby-ex ruby-ex closed this as completed Oct 7, 2016
@0xbug
Copy link
Owner

0xbug commented Oct 8, 2016

@ruby-ex 抱歉,忘记测试了

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

No branches or pull requests

2 participants