Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
pablodav
burp-ui
Commits
8a178930
Commit
8a178930
authored
Dec 15, 2016
by
Benjamin "Ziirish" SANS
Browse files
Merge branch 'master' into 'stable'
Master new stable release See merge request !55
parents
ac23ef56
b3fff881
Changes
8
Hide whitespace changes
Inline
Side-by-side
burpui/app.py
View file @
8a178930
...
...
@@ -113,7 +113,7 @@ def create_db(myapp, cli=False):
test_database
()
except
OperationalError
as
exp
:
if
'no such table'
in
str
(
exp
):
myapp
.
logger
.
error
(
myapp
.
logger
.
critical
(
'Your database seem out of sync, you may want '
'to run
\'
bui-manage db upgrade
\'
. Disabling '
'SQL support for now.'
...
...
@@ -122,8 +122,9 @@ def create_db(myapp, cli=False):
return
None
return
db
except
ImportError
:
myapp
.
logger
.
warning
(
'Unable to load requirements, SQL support disabled'
myapp
.
logger
.
critical
(
'Unable to load requirements, you may want to run
\'
pip '
'install "burp-ui[sql]"
\'
. Disabling SQL support for now.'
)
myapp
.
config
[
'WITH_SQL'
]
=
False
...
...
@@ -456,10 +457,7 @@ def create_app(conf=None, verbose=0, logfile=None, gunicorn=True,
babel
.
init_app
(
app
)
# Create SQLAlchemy if enabled
mcli
=
cli
if
unittest
:
mcli
=
True
create_db
(
app
,
mcli
)
create_db
(
app
,
cli
)
# We initialize the API
api
.
version
=
__version__
...
...
burpui/cli.py
View file @
8a178930
...
...
@@ -41,15 +41,21 @@ app = create_app(
cli
=
CLI
)
if
app
.
config
[
'WITH_SQL'
]:
try
:
from
.app
import
create_db
from
.ext.sql
import
db
from
flask_migrate
import
Migrate
app
.
config
[
'WITH_SQL'
]
=
True
create_db
(
app
,
True
)
mig_dir
=
os
.
getenv
(
'BUI_MIGRATIONS'
)
if
mig_dir
:
migrate
=
Migrate
(
app
,
db
,
mig_dir
)
else
:
migrate
=
Migrate
(
app
,
db
)
except
ImportError
:
pass
@
app
.
cli
.
command
()
...
...
docs/installation.rst
View file @
8a178930
...
...
@@ -4,15 +4,6 @@ Installation
`Burp-UI`_ is written in Python with the `Flask`_ micro-framework.
The easiest way to install `Burp-UI`_ is to use ``pip``.
On Debian, you can install ``pip`` with the following command:
::
aptitude install python-pip
Once ``pip`` is installed, you can install ``Burp-UI`` this way:
::
pip install burp-ui
...
...
@@ -32,7 +23,7 @@ virtualenv)
Then you can run ``burp-ui``: ``burp-ui``
By default, ``burp-ui`` listens on
all interfaces (including IPv6)
on port 5000.
By default, ``burp-ui`` listens on
localhost
on port 5000.
You can then point your browser to http://127.0.0.1:5000/
...
...
docs/requirements.rst
View file @
8a178930
...
...
@@ -24,7 +24,9 @@ Some libraries are required to be able to compile some requirements:
::
apt-get install libffi-dev libssl-dev python-dev
apt-get install libffi-dev libssl-dev python-dev python-pip
# this package conflicts with the pip requirements
apt-get remove python-cffi
Debian Wheezy
-------------
...
...
docs/upgrading.rst
View file @
8a178930
...
...
@@ -33,6 +33,9 @@ v0.4.0
``1`` since burp-2.0.52 is now the stable release.
- **New** - The ``bui-manage`` tool can now help you setup both `Burp`_ and
`Burp-UI`_.
- **New** - The SQL requirements have evolved, you **MUST** run
``pip install --upgrade "burp-ui[sql]"`` if you wish to keep using persistent
storage.
v0.3.0
...
...
setup.py
View file @
8a178930
...
...
@@ -254,7 +254,7 @@ setup(
'dev'
:
dev_requires
,
'debian_wheezy'
:
[
'functools32'
],
'celery'
:
[
'Celery'
,
'redis'
],
'sql'
:
[
'Flask-SQLAlchemy'
,
'Flask-Migrate
=
=2.0.1'
,
'sqlalchemy-utils'
],
'sql'
:
[
'Flask-SQLAlchemy'
,
'Flask-Migrate
>
=2.0.1'
,
'sqlalchemy-utils'
],
},
tests_require
=
test_requires
,
classifiers
=
[
...
...
test/run_build.sh
View file @
8a178930
...
...
@@ -22,18 +22,18 @@ $PYTHON setup.py bdist_egg
echo
"publishing build"
cd
dist
tgz
=
$(
ls
-1rt
dist/
burp-ui
*
.tar.gz |
tail
-1
)
egg
=
$(
ls
-1rt
dist/
burp_ui
*
.egg |
tail
-1
)
whl
=
$(
ls
-1rt
dist/
burp_ui
*
.whl |
tail
-1
)
tgz
=
$(
ls
-1rt
burp-ui
*
.tar.gz |
tail
-1
)
egg
=
$(
ls
-1rt
burp_ui
*
.egg |
tail
-1
)
whl
=
$(
ls
-1rt
burp_ui
*
.whl |
tail
-1
)
cd
..
cp
-vf
dist/burp-ui
*
.tar.gz /pub/ 2>/dev/null
cp
-vf
dist/burp_ui
*
.egg /pub/ 2>/dev/null
cp
-vf
dist/burp_ui
*
.whl /pub/ 2>/dev/null
cd
/pub
rm
burp-ui.dev.tar.gz burp_ui-dev-py
${
VERSION
}
.egg burp_ui-dev-py2.py3-none-any.whl 2>/dev/null
ln
-sf
$tgz
burp-ui.dev.tar.gz
ln
-sf
$egg
burp_ui-dev-py
${
VERSION
}
.egg
ln
-sf
$whl
burp_ui-dev-py2.py3-none-any.whl
#
rm burp-ui.dev.tar.gz burp_ui-dev-py${VERSION}.egg burp_ui-dev-py2.py3-none-any.whl 2>/dev/null
[
-n
"
$tgz
"
]
&&
ln
-sf
$tgz
burp-ui.dev.tar.gz
[
-n
"
$egg
"
]
&&
ln
-sf
$egg
burp_ui-dev-py
${
VERSION
}
.egg
[
-n
"
$whl
"
]
&&
ln
-sf
$whl
burp_ui-dev-py2.py3-none-any.whl
exit
0
test/test_burpui.py
View file @
8a178930
...
...
@@ -413,8 +413,11 @@ class BurpuiRedisTestCase(TestCase):
bui
.
config
[
'LOGIN_DISABLED'
]
=
False
bui
.
client
.
port
=
9999
with
bui
.
app_context
():
from
burpui.app
import
create_db
from
burpui.ext.sql
import
db
from
burpui.models
import
Session
,
Task
bui
.
config
[
'WITH_SQL'
]
=
True
create_db
(
bui
,
True
)
db
.
create_all
()
db
.
session
.
commit
()
return
bui
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment