├── .resources └── imgs │ ├── br-flag-tiny.svg │ ├── interface.gif │ ├── logo.svg │ └── panorama-2.0.0.png ├── CHANGELOG.md ├── Dockerfile ├── LICENSE ├── LICENSES ├── bootstrap-v4.0.0.txt ├── crossfilter.txt ├── cvss-calculator-v3.txt ├── d3.v3.js.txt ├── dc-js.txt ├── django.txt ├── jquery.min.js ├── jquery.mobile.min.js ├── poppler.min.js └── python-3.txt ├── README.md ├── base ├── base │ ├── __init__.py │ ├── asgi.py │ ├── settings.py │ ├── urls.py │ └── wsgi.py ├── catalog │ ├── __init__.py │ ├── admin.py │ ├── apps.py │ ├── authViews.py │ ├── crudViews.py │ ├── dataConverterViews.py │ ├── dataViews.py │ ├── exportViews.py │ ├── fixturename │ │ └── riskQuestions-example.json │ ├── forms.py │ ├── migrations │ │ ├── 0001_initial.py │ │ ├── __init__.py │ │ └── __pycache__ │ │ │ ├── 0001_initial.cpython-38.pyc │ │ │ └── __init__.cpython-38.pyc │ ├── models.py │ ├── searchViews.py │ ├── static │ │ ├── admin │ │ │ ├── css │ │ │ │ ├── autocomplete.css │ │ │ │ ├── base.css │ │ │ │ ├── changelists.css │ │ │ │ ├── dashboard.css │ │ │ │ ├── fonts.css │ │ │ │ ├── forms.css │ │ │ │ ├── login.css │ │ │ │ ├── nav_sidebar.css │ │ │ │ ├── responsive.css │ │ │ │ ├── responsive_rtl.css │ │ │ │ ├── rtl.css │ │ │ │ ├── vendor │ │ │ │ │ └── select2 │ │ │ │ │ │ ├── LICENSE-SELECT2.md │ │ │ │ │ │ ├── select2.css │ │ │ │ │ │ └── select2.min.css │ │ │ │ └── widgets.css │ │ │ ├── fonts │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── README.txt │ │ │ │ ├── Roboto-Bold-webfont.woff │ │ │ │ ├── Roboto-Light-webfont.woff │ │ │ │ └── Roboto-Regular-webfont.woff │ │ │ ├── img │ │ │ │ ├── LICENSE │ │ │ │ ├── README.txt │ │ │ │ ├── calendar-icons.svg │ │ │ │ ├── gis │ │ │ │ │ ├── move_vertex_off.svg │ │ │ │ │ └── move_vertex_on.svg │ │ │ │ ├── icon-addlink.svg │ │ │ │ ├── icon-alert.svg │ │ │ │ ├── icon-calendar.svg │ │ │ │ ├── icon-changelink.svg │ │ │ │ ├── icon-clock.svg │ │ │ │ ├── icon-deletelink.svg │ │ │ │ ├── icon-no.svg │ │ │ │ ├── icon-unknown-alt.svg │ │ │ │ ├── icon-unknown.svg │ │ │ │ ├── icon-viewlink.svg │ │ │ │ ├── icon-yes.svg │ │ │ │ ├── inline-delete.svg │ │ │ │ ├── search.svg │ │ │ │ ├── selector-icons.svg │ │ │ │ ├── sorting-icons.svg │ │ │ │ ├── tooltag-add.svg │ │ │ │ └── tooltag-arrowright.svg │ │ │ └── js │ │ │ │ ├── SelectBox.js │ │ │ │ ├── SelectFilter2.js │ │ │ │ ├── actions.js │ │ │ │ ├── admin │ │ │ │ ├── DateTimeShortcuts.js │ │ │ │ └── RelatedObjectLookups.js │ │ │ │ ├── autocomplete.js │ │ │ │ ├── calendar.js │ │ │ │ ├── cancel.js │ │ │ │ ├── change_form.js │ │ │ │ ├── collapse.js │ │ │ │ ├── core.js │ │ │ │ ├── inlines.js │ │ │ │ ├── jquery.init.js │ │ │ │ ├── nav_sidebar.js │ │ │ │ ├── popup_response.js │ │ │ │ ├── prepopulate.js │ │ │ │ ├── prepopulate_init.js │ │ │ │ ├── urlify.js │ │ │ │ └── vendor │ │ │ │ ├── jquery │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── jquery.js │ │ │ │ └── jquery.min.js │ │ │ │ ├── select2 │ │ │ │ ├── LICENSE.md │ │ │ │ ├── i18n │ │ │ │ │ ├── af.js │ │ │ │ │ ├── ar.js │ │ │ │ │ ├── az.js │ │ │ │ │ ├── bg.js │ │ │ │ │ ├── bn.js │ │ │ │ │ ├── bs.js │ │ │ │ │ ├── ca.js │ │ │ │ │ ├── cs.js │ │ │ │ │ ├── da.js │ │ │ │ │ ├── de.js │ │ │ │ │ ├── dsb.js │ │ │ │ │ ├── el.js │ │ │ │ │ ├── en.js │ │ │ │ │ ├── es.js │ │ │ │ │ ├── et.js │ │ │ │ │ ├── eu.js │ │ │ │ │ ├── fa.js │ │ │ │ │ ├── fi.js │ │ │ │ │ ├── fr.js │ │ │ │ │ ├── gl.js │ │ │ │ │ ├── he.js │ │ │ │ │ ├── hi.js │ │ │ │ │ ├── hr.js │ │ │ │ │ ├── hsb.js │ │ │ │ │ ├── hu.js │ │ │ │ │ ├── hy.js │ │ │ │ │ ├── id.js │ │ │ │ │ ├── is.js │ │ │ │ │ ├── it.js │ │ │ │ │ ├── ja.js │ │ │ │ │ ├── ka.js │ │ │ │ │ ├── km.js │ │ │ │ │ ├── ko.js │ │ │ │ │ ├── lt.js │ │ │ │ │ ├── lv.js │ │ │ │ │ ├── mk.js │ │ │ │ │ ├── ms.js │ │ │ │ │ ├── nb.js │ │ │ │ │ ├── ne.js │ │ │ │ │ ├── nl.js │ │ │ │ │ ├── pl.js │ │ │ │ │ ├── ps.js │ │ │ │ │ ├── pt-BR.js │ │ │ │ │ ├── pt.js │ │ │ │ │ ├── ro.js │ │ │ │ │ ├── ru.js │ │ │ │ │ ├── sk.js │ │ │ │ │ ├── sl.js │ │ │ │ │ ├── sq.js │ │ │ │ │ ├── sr-Cyrl.js │ │ │ │ │ ├── sr.js │ │ │ │ │ ├── sv.js │ │ │ │ │ ├── th.js │ │ │ │ │ ├── tk.js │ │ │ │ │ ├── tr.js │ │ │ │ │ ├── uk.js │ │ │ │ │ ├── vi.js │ │ │ │ │ ├── zh-CN.js │ │ │ │ │ └── zh-TW.js │ │ │ │ ├── select2.full.js │ │ │ │ └── select2.full.min.js │ │ │ │ └── xregexp │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── xregexp.js │ │ │ │ └── xregexp.min.js │ │ ├── css │ │ │ ├── bootstrap.min.css │ │ │ ├── bootstrap.min.css.map │ │ │ ├── catalog.css │ │ │ ├── dc.css │ │ │ └── dc.js.map │ │ ├── cvss │ │ │ ├── calculator │ │ │ │ ├── cvsscalc30.js │ │ │ │ └── cvsscalc30_helptext.js │ │ │ └── identity │ │ │ │ └── cvss_web.png │ │ ├── django_tinymce │ │ │ └── init_tinymce.js │ │ ├── imgs │ │ │ ├── artifacts │ │ │ │ ├── br-flag-tiny.svg │ │ │ │ ├── favicon.png │ │ │ │ ├── favicon.svg │ │ │ │ ├── logo-grayscale.svg │ │ │ │ └── logo.svg │ │ │ └── cvss │ │ │ │ └── identity │ │ │ │ └── cvss_web.png │ │ ├── js │ │ │ ├── bootstrap.min.js │ │ │ ├── bootstrap.min.js.map │ │ │ ├── crossfilter.js │ │ │ ├── cvsscalc30.js │ │ │ ├── cvsscalc30_helptext.js │ │ │ ├── d3.v3.js │ │ │ ├── dc.js │ │ │ ├── home-generator.js │ │ │ ├── html.helper.js │ │ │ ├── jquery.min.js │ │ │ ├── jquery.mobile.min.js │ │ │ ├── panorama-generator.js │ │ │ ├── popper.min.js │ │ │ ├── popper.min.js.map │ │ │ └── risk_calculator.js │ │ └── tinymce │ │ │ ├── changelog.txt │ │ │ ├── custom.js │ │ │ ├── icons │ │ │ └── default │ │ │ │ └── icons.min.js │ │ │ ├── jquery.tinymce.min.js │ │ │ ├── langs │ │ │ ├── ar.js │ │ │ ├── bg_BG.js │ │ │ ├── ca.js │ │ │ ├── cs.js │ │ │ ├── cy.js │ │ │ ├── da.js │ │ │ ├── de.js │ │ │ ├── es.js │ │ │ ├── es_ES.js │ │ │ ├── es_MX.js │ │ │ ├── eu.js │ │ │ ├── fa.js │ │ │ ├── fa_IR.js │ │ │ ├── fi.js │ │ │ ├── fr_FR.js │ │ │ ├── gl.js │ │ │ ├── he_IL.js │ │ │ ├── hr.js │ │ │ ├── hu_HU.js │ │ │ ├── id.js │ │ │ ├── it.js │ │ │ ├── it_IT.js │ │ │ ├── ja.js │ │ │ ├── kk.js │ │ │ ├── ko_KR.js │ │ │ ├── lt.js │ │ │ ├── nb_NO.js │ │ │ ├── nl.js │ │ │ ├── pl.js │ │ │ ├── pt_BR.js │ │ │ ├── pt_PT.js │ │ │ ├── readme.md │ │ │ ├── ro.js │ │ │ ├── ro_RO.js │ │ │ ├── ru.js │ │ │ ├── sk.js │ │ │ ├── sl.js │ │ │ ├── sl_SI.js │ │ │ ├── sv_SE.js │ │ │ ├── ta.js │ │ │ ├── ta_IN.js │ │ │ ├── th_TH.js │ │ │ ├── tr.js │ │ │ ├── tr_TR.js │ │ │ ├── uk.js │ │ │ ├── zh_CN.js │ │ │ └── zh_TW.js │ │ │ ├── license.txt │ │ │ ├── plugins │ │ │ ├── advlist │ │ │ │ └── plugin.min.js │ │ │ ├── anchor │ │ │ │ └── plugin.min.js │ │ │ ├── autolink │ │ │ │ └── plugin.min.js │ │ │ ├── autoresize │ │ │ │ └── plugin.min.js │ │ │ ├── autosave │ │ │ │ └── plugin.min.js │ │ │ ├── bbcode │ │ │ │ └── plugin.min.js │ │ │ ├── charmap │ │ │ │ └── plugin.min.js │ │ │ ├── code │ │ │ │ └── plugin.min.js │ │ │ ├── codesample │ │ │ │ └── plugin.min.js │ │ │ ├── colorpicker │ │ │ │ └── plugin.min.js │ │ │ ├── contextmenu │ │ │ │ └── plugin.min.js │ │ │ ├── directionality │ │ │ │ └── plugin.min.js │ │ │ ├── emoticons │ │ │ │ ├── js │ │ │ │ │ ├── emojis.js │ │ │ │ │ └── emojis.min.js │ │ │ │ └── plugin.min.js │ │ │ ├── fullpage │ │ │ │ └── plugin.min.js │ │ │ ├── fullscreen │ │ │ │ └── plugin.min.js │ │ │ ├── help │ │ │ │ └── plugin.min.js │ │ │ ├── hr │ │ │ │ └── plugin.min.js │ │ │ ├── image │ │ │ │ └── plugin.min.js │ │ │ ├── imagetools │ │ │ │ └── plugin.min.js │ │ │ ├── importcss │ │ │ │ └── plugin.min.js │ │ │ ├── insertdatetime │ │ │ │ └── plugin.min.js │ │ │ ├── legacyoutput │ │ │ │ └── plugin.min.js │ │ │ ├── link │ │ │ │ └── plugin.min.js │ │ │ ├── lists │ │ │ │ └── plugin.min.js │ │ │ ├── media │ │ │ │ └── plugin.min.js │ │ │ ├── nonbreaking │ │ │ │ └── plugin.min.js │ │ │ ├── noneditable │ │ │ │ └── plugin.min.js │ │ │ ├── pagebreak │ │ │ │ └── plugin.min.js │ │ │ ├── paste │ │ │ │ └── plugin.min.js │ │ │ ├── preview │ │ │ │ └── plugin.min.js │ │ │ ├── print │ │ │ │ └── plugin.min.js │ │ │ ├── quickbars │ │ │ │ └── plugin.min.js │ │ │ ├── save │ │ │ │ └── plugin.min.js │ │ │ ├── searchreplace │ │ │ │ └── plugin.min.js │ │ │ ├── spellchecker │ │ │ │ └── plugin.min.js │ │ │ ├── tabfocus │ │ │ │ └── plugin.min.js │ │ │ ├── table │ │ │ │ └── plugin.min.js │ │ │ ├── template │ │ │ │ └── plugin.min.js │ │ │ ├── textcolor │ │ │ │ └── plugin.min.js │ │ │ ├── textpattern │ │ │ │ └── plugin.min.js │ │ │ ├── toc │ │ │ │ └── plugin.min.js │ │ │ ├── visualblocks │ │ │ │ └── plugin.min.js │ │ │ ├── visualchars │ │ │ │ └── plugin.min.js │ │ │ └── wordcount │ │ │ │ └── plugin.min.js │ │ │ ├── skins │ │ │ ├── content │ │ │ │ ├── dark │ │ │ │ │ └── content.min.css │ │ │ │ ├── default │ │ │ │ │ └── content.min.css │ │ │ │ ├── document │ │ │ │ │ └── content.min.css │ │ │ │ └── writer │ │ │ │ │ └── content.min.css │ │ │ └── ui │ │ │ │ ├── oxide-dark │ │ │ │ ├── content.inline.min.css │ │ │ │ ├── content.min.css │ │ │ │ ├── content.mobile.min.css │ │ │ │ ├── fonts │ │ │ │ │ └── tinymce-mobile.woff │ │ │ │ ├── skin.min.css │ │ │ │ ├── skin.mobile.min.css │ │ │ │ └── tinymce-mobile.woff │ │ │ │ └── oxide │ │ │ │ ├── content.inline.min.css │ │ │ │ ├── content.min.css │ │ │ │ ├── content.mobile.min.css │ │ │ │ ├── fonts │ │ │ │ └── tinymce-mobile.woff │ │ │ │ ├── skin.min.css │ │ │ │ ├── skin.mobile.min.css │ │ │ │ └── tinymce-mobile.woff │ │ │ ├── themes │ │ │ ├── mobile │ │ │ │ └── theme.min.js │ │ │ └── silver │ │ │ │ └── theme.min.js │ │ │ └── tinymce.min.js │ ├── templates │ │ └── catalog │ │ │ ├── add.html │ │ │ ├── converter.html │ │ │ ├── delete.html │ │ │ ├── detail.html │ │ │ ├── fastupdate.html │ │ │ ├── home.html │ │ │ ├── index.html │ │ │ ├── login.html │ │ │ ├── panorama.html │ │ │ ├── search.html │ │ │ ├── update.html │ │ │ └── upload.html │ ├── tests.py │ ├── uploadFileViews.py │ ├── urls.py │ └── views.py ├── manage.py └── run_cherrypy.py ├── requirements.txt ├── run.sh ├── setup.sh ├── test ├── data │ ├── data-md.json │ ├── data-sm.json │ └── riskQuestions-example.json └── tools │ └── testDataGenerator.py └── tools ├── deployDocker.sh ├── genSessionKey.py ├── nessus2catalog.py └── openvas2catalog.py /.resources/imgs/interface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/.resources/imgs/interface.gif -------------------------------------------------------------------------------- /.resources/imgs/panorama-2.0.0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/.resources/imgs/panorama-2.0.0.png -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## vulnerability-catalog-3.0.0 2 | 3 | 4 | **Changes since the previous release:** 5 | - Removed support for automatic setup on Windows machines: 6 | It still works on Windows but the setup needs to be done manually. 7 | - New layout for the project: 8 | Simplified the old directory structure for better maintainance. 9 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | # Check https://github.com/daavelino/vulnerability-catalog/wiki/Using-Docker-to-run-Catalog 2 | 3 | # Use an official Python 3 runtime as a parent image 4 | FROM python:3.6 5 | 6 | # Set apps home directory: 7 | WORKDIR . 8 | 9 | # Adds the application code to the image: 10 | ADD . ${APP_DIR} 11 | 12 | # Build the project structure without Python's Virtual Environment 13 | RUN apt-get update && apt-get install -y libxml2-dev libxmlsec1-dev 14 | RUN python setup.py build-novenv 15 | 16 | # Setup Admin user. Change it properly: 17 | ENV DJANGO_SU_NAME=admin 18 | ENV DJANGO_SU_EMAIL=admin@example.com 19 | ENV DJANGO_SU_PASSWORD=vcatalog 20 | 21 | # Server variables 22 | ENV HOSTNAME=localhost 23 | ENV PORT=8000 24 | 25 | RUN echo "from django.contrib.auth import get_user_model; User = get_user_model(); User.objects.create_superuser('${DJANGO_SU_NAME}', '${DJANGO_SU_EMAIL}', '${DJANGO_SU_PASSWORD}')" | python base/manage.py shell 26 | 27 | # Make port 8000 available to the world outside this container: 28 | EXPOSE 8000 29 | 30 | # Lauch Catalog. Make sure to set IP address and port properly: 31 | WORKDIR base 32 | CMD ["./run.sh","${HOSTNAME}:${PORT}"] 33 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Daniel Avelino 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /LICENSES/bootstrap-v4.0.0.txt: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://github.com/twbs/bootstrap/blob/master/LICENSE 4 | 5 | The MIT License (MIT) 6 | 7 | Copyright (c) 2011-2016 Twitter, Inc. 8 | 9 | Permission is hereby granted, free of charge, to any person obtaining a copy 10 | of this software and associated documentation files (the "Software"), to deal 11 | in the Software without restriction, including without limitation the rights 12 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 13 | copies of the Software, and to permit persons to whom the Software is 14 | furnished to do so, subject to the following conditions: 15 | 16 | The above copyright notice and this permission notice shall be included in 17 | all copies or substantial portions of the Software. 18 | 19 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 20 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 21 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 22 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 23 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 24 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 25 | THE SOFTWARE. 26 | -------------------------------------------------------------------------------- /LICENSES/crossfilter.txt: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://github.com/square/crossfilter/blob/master/LICENSE 4 | 5 | Copyright 2012 Square, Inc. 6 | 7 | Licensed under the Apache License, Version 2.0 (the "License"); you may not use 8 | this file except in compliance with the License. You may obtain a copy of the 9 | License at 10 | 11 | http://www.apache.org/licenses/LICENSE-2.0 12 | 13 | Unless required by applicable law or agreed to in writing, software distributed 14 | under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 15 | CONDITIONS OF ANY KIND, either express or implied. See the License for the 16 | specific language governing permissions and limitations under the License. 17 | -------------------------------------------------------------------------------- /LICENSES/d3.v3.js.txt: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://github.com/d3/d3/blob/master/LICENSE 4 | 5 | Copyright 2010-2017 Mike Bostock 6 | All rights reserved. 7 | 8 | Redistribution and use in source and binary forms, with or without modification, 9 | are permitted provided that the following conditions are met: 10 | 11 | * Redistributions of source code must retain the above copyright notice, this 12 | list of conditions and the following disclaimer. 13 | 14 | * Redistributions in binary form must reproduce the above copyright notice, 15 | this list of conditions and the following disclaimer in the documentation 16 | and/or other materials provided with the distribution. 17 | 18 | * Neither the name of the author nor the names of contributors may be used to 19 | endorse or promote products derived from this software without specific prior 20 | written permission. 21 | 22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 23 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 24 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 25 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 26 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 27 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON 29 | ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 30 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 31 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 32 | -------------------------------------------------------------------------------- /LICENSES/django.txt: -------------------------------------------------------------------------------- 1 | 2 | As stated at: 3 | 4 | https://github.com/django/djangoproject.com/blob/master/LICENSE 5 | 6 | 7 | 8 | Copyright (c) Django Software Foundation and individual contributors. 9 | All rights reserved. 10 | 11 | Redistribution and use in source and binary forms, with or without modification, 12 | are permitted provided that the following conditions are met: 13 | 14 | 1. Redistributions of source code must retain the above copyright notice, 15 | this list of conditions and the following disclaimer. 16 | 17 | 2. Redistributions in binary form must reproduce the above copyright 18 | notice, this list of conditions and the following disclaimer in the 19 | documentation and/or other materials provided with the distribution. 20 | 21 | 3. Neither the name of Django nor the names of its contributors may be used 22 | to endorse or promote products derived from this software without 23 | specific prior written permission. 24 | 25 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 26 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 27 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 28 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 29 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 30 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 31 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON 32 | ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 33 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 34 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 35 | -------------------------------------------------------------------------------- /LICENSES/jquery.min.js: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://github.com/jquery/jquery/blob/master/LICENSE.txt 4 | 5 | Copyright JS Foundation and other contributors, https://js.foundation/ 6 | 7 | This software consists of voluntary contributions made by many 8 | individuals. For exact contribution history, see the revision history 9 | available at https://github.com/jquery/jquery 10 | 11 | The following license applies to all parts of this software except as 12 | documented below: 13 | 14 | ==== 15 | 16 | Permission is hereby granted, free of charge, to any person obtaining 17 | a copy of this software and associated documentation files (the 18 | "Software"), to deal in the Software without restriction, including 19 | without limitation the rights to use, copy, modify, merge, publish, 20 | distribute, sublicense, and/or sell copies of the Software, and to 21 | permit persons to whom the Software is furnished to do so, subject to 22 | the following conditions: 23 | 24 | The above copyright notice and this permission notice shall be 25 | included in all copies or substantial portions of the Software. 26 | 27 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 28 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 29 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 30 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 31 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 32 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 33 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 34 | 35 | ==== 36 | 37 | All files located in the node_modules and external directories are 38 | externally maintained libraries used by this software which have their 39 | own licenses; we recommend you read them, as their terms may differ from 40 | the terms above. 41 | 42 | -------------------------------------------------------------------------------- /LICENSES/jquery.mobile.min.js: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://github.com/jquery/jquery/blob/master/LICENSE.txt 4 | 5 | Copyright JS Foundation and other contributors, https://js.foundation/ 6 | 7 | This software consists of voluntary contributions made by many 8 | individuals. For exact contribution history, see the revision history 9 | available at https://github.com/jquery/jquery 10 | 11 | The following license applies to all parts of this software except as 12 | documented below: 13 | 14 | ==== 15 | 16 | Permission is hereby granted, free of charge, to any person obtaining 17 | a copy of this software and associated documentation files (the 18 | "Software"), to deal in the Software without restriction, including 19 | without limitation the rights to use, copy, modify, merge, publish, 20 | distribute, sublicense, and/or sell copies of the Software, and to 21 | permit persons to whom the Software is furnished to do so, subject to 22 | the following conditions: 23 | 24 | The above copyright notice and this permission notice shall be 25 | included in all copies or substantial portions of the Software. 26 | 27 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 28 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 29 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 30 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 31 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 32 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 33 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 34 | 35 | ==== 36 | 37 | All files located in the node_modules and external directories are 38 | externally maintained libraries used by this software which have their 39 | own licenses; we recommend you read them, as their terms may differ from 40 | the terms above. 41 | 42 | -------------------------------------------------------------------------------- /LICENSES/poppler.min.js: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://github.com/FezVrasta/popper.js/blob/master/LICENSE.md 4 | 5 | The MIT License (MIT) 6 | ===================== 7 | 8 | Copyright © 2016 Federico Zivolo and contributors 9 | 10 | Permission is hereby granted, free of charge, to any person 11 | obtaining a copy of this software and associated documentation 12 | files (the “Software”), to deal in the Software without 13 | restriction, including without limitation the rights to use, 14 | copy, modify, merge, publish, distribute, sublicense, and/or sell 15 | copies of the Software, and to permit persons to whom the 16 | Software is furnished to do so, subject to the following 17 | conditions: 18 | 19 | The above copyright notice and this permission notice shall be 20 | included in all copies or substantial portions of the Software. 21 | 22 | THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, 23 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 24 | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 25 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 26 | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 27 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 28 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 29 | OTHER DEALINGS IN THE SOFTWARE. 30 | -------------------------------------------------------------------------------- /LICENSES/python-3.txt: -------------------------------------------------------------------------------- 1 | As stated at: 2 | 3 | https://docs.python.org/3/license.html 4 | 5 | 6 | 1. This LICENSE AGREEMENT is between the Python Software Foundation ("PSF"), and 7 | the Individual or Organization ("Licensee") accessing and otherwise using Python 8 | 3.6.4 software in source or binary form and its associated documentation. 9 | 10 | 2. Subject to the terms and conditions of this License Agreement, PSF hereby 11 | grants Licensee a nonexclusive, royalty-free, world-wide license to reproduce, 12 | analyze, test, perform and/or display publicly, prepare derivative works, 13 | distribute, and otherwise use Python 3.6.4 alone or in any derivative 14 | version, provided, however, that PSF's License Agreement and PSF's notice of 15 | copyright, i.e., "Copyright © 2001-2018 Python Software Foundation; All Rights 16 | Reserved" are retained in Python 3.6.4 alone or in any derivative version 17 | prepared by Licensee. 18 | 19 | 3. In the event Licensee prepares a derivative work that is based on or 20 | incorporates Python 3.6.4 or any part thereof, and wants to make the 21 | derivative work available to others as provided herein, then Licensee hereby 22 | agrees to include in any such work a brief summary of the changes made to Python 23 | 3.6.4. 24 | 25 | 4. PSF is making Python 3.6.4 available to Licensee on an "AS IS" basis. 26 | PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED. BY WAY OF 27 | EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND DISCLAIMS ANY REPRESENTATION OR 28 | WARRANTY OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE 29 | USE OF PYTHON 3.6.4 WILL NOT INFRINGE ANY THIRD PARTY RIGHTS. 30 | 31 | 5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON 3.6.4 32 | FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS A RESULT OF 33 | MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 3.6.4, OR ANY DERIVATIVE 34 | THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. 35 | 36 | 6. This License Agreement will automatically terminate upon a material breach of 37 | its terms and conditions. 38 | 39 | 7. Nothing in this License Agreement shall be deemed to create any relationship 40 | of agency, partnership, or joint venture between PSF and Licensee. This License 41 | Agreement does not grant permission to use PSF trademarks or trade name in a 42 | trademark sense to endorse or promote products or services of Licensee, or any 43 | third party. 44 | 45 | 8. By copying, installing or otherwise using Python 3.6.4, Licensee agrees 46 | to be bound by the terms and conditions of this License Agreement. 47 | 48 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | 3 |

4 | 5 | Welcome to Vulnerability Catalog project, a catalog for Information Security Management designed for environments with **multiple or diffuse vulnerability-related information sources**. 6 | 7 | >[Check the latest release](https://github.com/daavelino/vulnerability-catalog/releases) 8 | 9 | [![Known Vulnerabilities](https://snyk.io/test/github/daavelino/vulnerability-catalog/badge.svg?targetFile=requirements.txt)](https://snyk.io/test/github/daavelino/vulnerability-catalog?targetFile=requirements.txt) 10 | [![Maintainability](https://api.codeclimate.com/v1/badges/79aebad49ab08c14656c/maintainability)](https://codeclimate.com/github/daavelino/vulnerability-catalog/maintainability) 11 | 12 | 13 | ### Install & run the Catalog 14 | ```sh 15 | git clone https://github.com/daavelino/vulnerability-catalog 16 | cd vulnerability-catalog 17 | ./setup.sh # only during the first install 18 | ./run.sh 19 | ``` 20 | 21 | * Test the Catalog by [importing a testing dataset](https://github.com/daavelino/vulnerability-catalog/wiki/Running-the-Catalog-with-testing-data). 22 | 23 | ### Features 24 | 25 | * Consistent track of the entire vulnerability lifecycle in a single place. 26 | * Standardized description and quantification of the vulnerabilities. 27 | * Risk and severity calculators to support precise quantification. 28 | * Dashboard to visualize the progress and attention points. 29 | * Easily import of the vulnerabilities found by Nessus or OpenVAS. 30 | 31 | Check the [Wiki](https://github.com/daavelino/vulnerability-catalog/wiki) for more information. 32 | 33 | ### Why a Catalog? 34 | Storing and keep track of all vulnerabilities found on your environment by using a centralized, easy to use and organized catalogue is a way more secure than using the traditional spreadsheets. 35 | 36 | With the Panorama, gain insights about what needs to be improved, track progress and effort, design better strategies and reduce risks by visualising the environment as a whole. 37 | 38 |

39 | 41 | 42 | 43 | ### Motivation 44 | 45 | The idea to start this effort came from my experience trying to keep track of vulnerabilities during the Olympic and Paralympic Games at Rio 2016 - The Rio de Janeiro Olympics. During that time, I realized three hard things about vulnerability management: 46 | 47 | 1. it is hard to **centralize all information** we got from vulnerability reports, assessments, pentests, user/peers report in a consistent way. 48 | 2. it is hard to put **relevant information**, like risks and severity, **in a common (and normalized) base**. 49 | 3. it is hard to **visualize and get insights** about the enviroment **when we have multiple and diffuse sources of data**, comming from .pdf, .xslx, .doc files or even by e-mail or other channels. 50 | 51 | So, Vulnerability Catalog try to make things a little bit easier. With Catalog, we can unify, put data into a normal basis and manage vulnerabilities better than if you try to do this by using sheets or search and reading reports one-by-one each time you need an information. 52 | 53 | ### Deploying to production 54 | 55 | Please check the [wiki](https://github.com/daavelino/vulnerability-catalog/wiki/Deploying-to-production) for a step-by-step approach. 56 | 57 | ### Many many thanks to 58 | 59 | * Victor Carvalho (https://www.behance.net/VictorjCarvalho), for logo design. 60 | * Barbara Camara for suggestions and point me the right persons. 61 | * Andrea Fabrete, for important improvement insights and suggestions. 62 | * Beatriz Lima, for watching changes and suggest new ideas. 63 | * Paulo Caldas, for stress the project concept, making it more mature. 64 | * Leandro Silva, for testing and report great feedback. 65 | 66 | and others (you know who you are) for important feedbacks and to keep me straight in my path. 67 | 68 | --- 69 | **License:** MIT License. **Author:** Daniel Avelino 70 | 71 |

72 | Proudly made in . 73 |

74 | -------------------------------------------------------------------------------- /base/base/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/base/__init__.py -------------------------------------------------------------------------------- /base/base/asgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | ASGI config for base project. 3 | 4 | It exposes the ASGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.2/howto/deployment/asgi/ 8 | """ 9 | 10 | import os 11 | 12 | from django.core.asgi import get_asgi_application 13 | 14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'base.settings') 15 | 16 | application = get_asgi_application() 17 | -------------------------------------------------------------------------------- /base/base/urls.py: -------------------------------------------------------------------------------- 1 | """base URL Configuration""" 2 | from django.urls import include, path 3 | from django.contrib import admin 4 | from django.views.generic.base import RedirectView 5 | from catalog.admin import admin_site 6 | 7 | urlpatterns = [ 8 | path('', RedirectView.as_view(url='catalog/')), 9 | path('catalog/', include('catalog.urls', namespace='catalog')), 10 | path('admin/', admin_site.urls), 11 | ] 12 | -------------------------------------------------------------------------------- /base/base/wsgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | WSGI config for base project. 3 | 4 | It exposes the WSGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/3.2/howto/deployment/wsgi/ 8 | """ 9 | 10 | import os 11 | 12 | from django.core.wsgi import get_wsgi_application 13 | 14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'base.settings') 15 | 16 | application = get_wsgi_application() 17 | -------------------------------------------------------------------------------- /base/catalog/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/__init__.py -------------------------------------------------------------------------------- /base/catalog/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib.admin import ModelAdmin 2 | from django.contrib.admin import AdminSite 3 | from django.contrib.admin import register 4 | 5 | from django.contrib.auth.models import Group, User 6 | from django.contrib.auth.admin import GroupAdmin, UserAdmin 7 | 8 | from .models import RiskQuestions 9 | 10 | # Register your models here. 11 | @register(RiskQuestions) 12 | class RiskQuestionsAdmin(ModelAdmin): 13 | list_display = ('position', 'question', 'question_shortname') 14 | list_display_links = ('position', 'question') 15 | 16 | class CustomAdminSite(AdminSite): 17 | site_header = 'Catalog administration' 18 | 19 | admin_site = CustomAdminSite(name = 'admin') 20 | admin_site.register(RiskQuestions, RiskQuestionsAdmin) 21 | admin_site.register(Group, GroupAdmin) 22 | admin_site.register(User, UserAdmin) 23 | -------------------------------------------------------------------------------- /base/catalog/apps.py: -------------------------------------------------------------------------------- 1 | from django.apps import AppConfig 2 | 3 | 4 | class CatalogConfig(AppConfig): 5 | default_auto_field = 'django.db.models.BigAutoField' 6 | name = 'catalog' 7 | -------------------------------------------------------------------------------- /base/catalog/authViews.py: -------------------------------------------------------------------------------- 1 | from django.contrib.auth import login, logout 2 | from django.contrib.auth.forms import AuthenticationForm 3 | from django.http import HttpRequest 4 | from django.shortcuts import redirect 5 | from django.utils.decorators import method_decorator 6 | from django.views import View 7 | from django.views.decorators.cache import never_cache 8 | from django.views.decorators.csrf import csrf_protect 9 | from django.views.decorators.debug import sensitive_post_parameters 10 | from django.views.generic.edit import FormView 11 | 12 | 13 | class LoginView(FormView): 14 | template_name = 'catalog/login.html' 15 | success_url = '/catalog/' 16 | form_class = AuthenticationForm 17 | 18 | @method_decorator(sensitive_post_parameters()) 19 | @method_decorator(csrf_protect) 20 | @method_decorator(never_cache) 21 | def dispatch(self, request, *args, **kwargs): 22 | request.session.set_test_cookie() 23 | return super(LoginView, self).dispatch(request, *args, **kwargs) 24 | 25 | def get_form_kwargs(self): 26 | kwargs = super(LoginView, self).get_form_kwargs() 27 | kwargs.update({"request": self.request}) 28 | return kwargs 29 | 30 | def form_valid(self, form): 31 | login(self.request, form.get_user()) 32 | 33 | if self.request.session.test_cookie_worked(): 34 | self.request.session.delete_test_cookie() 35 | 36 | return super(LoginView, self).form_valid(form) 37 | 38 | class LogoutView(View): 39 | 40 | def logout_user(HttpRequest): 41 | redirect_url = '/catalog/accounts/login/' 42 | logout(HttpRequest) 43 | return redirect(redirect_url) 44 | 45 | 46 | -------------------------------------------------------------------------------- /base/catalog/dataConverterViews.py: -------------------------------------------------------------------------------- 1 | 2 | 3 | from django.contrib.auth.decorators import login_required, permission_required 4 | from django.utils.decorators import method_decorator 5 | from django.shortcuts import render 6 | from django.views.generic import TemplateView 7 | 8 | from .models import Vulnerability 9 | 10 | decorators = [login_required(login_url='catalog:login')] 11 | 12 | @method_decorator(decorators, name='dispatch') 13 | @method_decorator(permission_required('catalog.read_vulnerability', \ 14 | raise_exception=True), name='dispatch') 15 | class DataConverter(TemplateView): 16 | ''' /catalog/resources/data/converter/ ''' 17 | model = Vulnerability 18 | template_name = 'catalog/converter.html' 19 | -------------------------------------------------------------------------------- /base/catalog/exportViews.py: -------------------------------------------------------------------------------- 1 | from datetime import datetime 2 | 3 | from django.contrib.auth.decorators import login_required, permission_required 4 | from django.core import serializers 5 | from django.http import HttpRequest, HttpResponse, HttpResponseForbidden 6 | from django.utils.decorators import method_decorator 7 | from django.views.generic import ListView 8 | 9 | from .models import Vulnerability, RiskQuestions 10 | 11 | login_url='catalog:login' 12 | decorators = [login_required(login_url=login_url)] 13 | 14 | today = datetime.today().strftime('%Y-%b-%d-%H%M') 15 | output_file = 'VC-export-' + today + '.json' 16 | 17 | @method_decorator(decorators, name='dispatch') 18 | @method_decorator(permission_required('catalog.detail_vulnerability', \ 19 | raise_exception=True), name='dispatch') 20 | class JsonExportView(ListView): 21 | '''/catalog/vulnerability/data/json/export''' 22 | '''Exports vulnerabilities and risk questions to a JSON file.''' 23 | 24 | def export_database(HttpRequest): 25 | if not HttpRequest.user.is_authenticated: 26 | return HttpResponseRedirect(reverse(login_url)) 27 | if not HttpRequest.user.has_perm('catalog.detail_vulnerability'): 28 | return HttpResponseForbidden('

403 Forbidden

') 29 | 30 | all_objects = list(Vulnerability.objects.all()) \ 31 | + list(RiskQuestions.objects.all()) 32 | result = serializers.serialize('json', all_objects) 33 | response = HttpResponse(result, content_type='application/json') 34 | response['Content-Disposition'] = 'attachment; filename=' + output_file 35 | 36 | return response 37 | -------------------------------------------------------------------------------- /base/catalog/fixturename/riskQuestions-example.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "model": "catalog.riskquestions", 4 | "pk": 1, 5 | "fields": { 6 | "position": 0, 7 | "question": "From the correct exploitation of the vulnerability, business should expect: (Keep in mind the simplest possibility of exploitation.)", 8 | "question_shortname": "Header", 9 | "weight": 1 10 | } 11 | }, 12 | { 13 | "model": "catalog.riskquestions", 14 | "pk": 2, 15 | "fields": { 16 | "position": 1, 17 | "question": "Volume of business information prone to becoming out of control:", 18 | "question_shortname": "BI", 19 | "weight": 1 20 | } 21 | }, 22 | { 23 | "model": "catalog.riskquestions", 24 | "pk": 3, 25 | "fields": { 26 | "position": 2, 27 | "question": "Business functions threatened of interruption due to the vulnerability exploitation:", 28 | "question_shortname": "BF", 29 | "weight": 1 30 | } 31 | }, 32 | { 33 | "model": "catalog.riskquestions", 34 | "pk": 4, 35 | "fields": { 36 | "position": 3, 37 | "question": "Strategic business information at risk due to the vulnerability:", 38 | "question_shortname": "SI", 39 | "weight": 1 40 | } 41 | }, 42 | { 43 | "model": "catalog.riskquestions", 44 | "pk": 5, 45 | "fields": { 46 | "position": 4, 47 | "question": "Legal or regulatory penalties due to the vulnerability:", 48 | "question_shortname":"LR", 49 | "weight": 1 50 | } 51 | }, 52 | { 53 | "model": "catalog.riskquestions", 54 | "pk": 6, 55 | "fields": { 56 | "position": 5, 57 | "question": "The estimated effort to remove the vulnerability:", 58 | "question_shortname":"EE", 59 | "weight": 1 60 | } 61 | } 62 | ] 63 | -------------------------------------------------------------------------------- /base/catalog/migrations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/migrations/__init__.py -------------------------------------------------------------------------------- /base/catalog/migrations/__pycache__/0001_initial.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/migrations/__pycache__/0001_initial.cpython-38.pyc -------------------------------------------------------------------------------- /base/catalog/migrations/__pycache__/__init__.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/migrations/__pycache__/__init__.cpython-38.pyc -------------------------------------------------------------------------------- /base/catalog/static/admin/css/dashboard.css: -------------------------------------------------------------------------------- 1 | /* DASHBOARD */ 2 | 3 | .dashboard .module table th { 4 | width: 100%; 5 | } 6 | 7 | .dashboard .module table td { 8 | white-space: nowrap; 9 | } 10 | 11 | .dashboard .module table td a { 12 | display: block; 13 | padding-right: .6em; 14 | } 15 | 16 | /* RECENT ACTIONS MODULE */ 17 | 18 | .module ul.actionlist { 19 | margin-left: 0; 20 | } 21 | 22 | ul.actionlist li { 23 | list-style-type: none; 24 | overflow: hidden; 25 | text-overflow: ellipsis; 26 | } 27 | -------------------------------------------------------------------------------- /base/catalog/static/admin/css/fonts.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: 'Roboto'; 3 | src: url('../fonts/Roboto-Bold-webfont.woff'); 4 | font-weight: 700; 5 | font-style: normal; 6 | } 7 | 8 | @font-face { 9 | font-family: 'Roboto'; 10 | src: url('../fonts/Roboto-Regular-webfont.woff'); 11 | font-weight: 400; 12 | font-style: normal; 13 | } 14 | 15 | @font-face { 16 | font-family: 'Roboto'; 17 | src: url('../fonts/Roboto-Light-webfont.woff'); 18 | font-weight: 300; 19 | font-style: normal; 20 | } 21 | -------------------------------------------------------------------------------- /base/catalog/static/admin/css/login.css: -------------------------------------------------------------------------------- 1 | /* LOGIN FORM */ 2 | 3 | .login { 4 | background: var(--darkened-bg); 5 | height: auto; 6 | } 7 | 8 | .login #header { 9 | height: auto; 10 | padding: 15px 16px; 11 | justify-content: center; 12 | } 13 | 14 | .login #header h1 { 15 | font-size: 18px; 16 | } 17 | 18 | .login #header h1 a { 19 | color: var(--header-link-color); 20 | } 21 | 22 | .login #content { 23 | padding: 20px 20px 0; 24 | } 25 | 26 | .login #container { 27 | background: var(--body-bg); 28 | border: 1px solid var(--hairline-color); 29 | border-radius: 4px; 30 | overflow: hidden; 31 | width: 28em; 32 | min-width: 300px; 33 | margin: 100px auto; 34 | height: auto; 35 | } 36 | 37 | .login .form-row { 38 | padding: 4px 0; 39 | } 40 | 41 | .login .form-row label { 42 | display: block; 43 | line-height: 2em; 44 | } 45 | 46 | .login .form-row #id_username, .login .form-row #id_password { 47 | padding: 8px; 48 | width: 100%; 49 | box-sizing: border-box; 50 | } 51 | 52 | .login .submit-row { 53 | padding: 1em 0 0 0; 54 | margin: 0; 55 | text-align: center; 56 | } 57 | 58 | .login .password-reset-link { 59 | text-align: center; 60 | } 61 | -------------------------------------------------------------------------------- /base/catalog/static/admin/css/nav_sidebar.css: -------------------------------------------------------------------------------- 1 | .sticky { 2 | position: sticky; 3 | top: 0; 4 | max-height: 100vh; 5 | } 6 | 7 | .toggle-nav-sidebar { 8 | z-index: 20; 9 | left: 0; 10 | display: flex; 11 | align-items: center; 12 | justify-content: center; 13 | flex: 0 0 23px; 14 | width: 23px; 15 | border: 0; 16 | border-right: 1px solid var(--hairline-color); 17 | background-color: var(--body-bg); 18 | cursor: pointer; 19 | font-size: 20px; 20 | color: var(--link-fg); 21 | padding: 0; 22 | } 23 | 24 | [dir="rtl"] .toggle-nav-sidebar { 25 | border-left: 1px solid var(--hairline-color); 26 | border-right: 0; 27 | } 28 | 29 | .toggle-nav-sidebar:hover, 30 | .toggle-nav-sidebar:focus { 31 | background-color: var(--darkened-bg); 32 | } 33 | 34 | #nav-sidebar { 35 | z-index: 15; 36 | flex: 0 0 275px; 37 | left: -276px; 38 | margin-left: -276px; 39 | border-top: 1px solid transparent; 40 | border-right: 1px solid var(--hairline-color); 41 | background-color: var(--body-bg); 42 | overflow: auto; 43 | } 44 | 45 | [dir="rtl"] #nav-sidebar { 46 | border-left: 1px solid var(--hairline-color); 47 | border-right: 0; 48 | left: 0; 49 | margin-left: 0; 50 | right: -276px; 51 | margin-right: -276px; 52 | } 53 | 54 | .toggle-nav-sidebar::before { 55 | content: '\00BB'; 56 | } 57 | 58 | .main.shifted .toggle-nav-sidebar::before { 59 | content: '\00AB'; 60 | } 61 | 62 | .main.shifted > #nav-sidebar { 63 | left: 24px; 64 | margin-left: 0; 65 | } 66 | 67 | [dir="rtl"] .main.shifted > #nav-sidebar { 68 | left: 0; 69 | right: 24px; 70 | margin-right: 0; 71 | } 72 | 73 | #nav-sidebar .module th { 74 | width: 100%; 75 | overflow-wrap: anywhere; 76 | } 77 | 78 | #nav-sidebar .module th, 79 | #nav-sidebar .module caption { 80 | padding-left: 16px; 81 | } 82 | 83 | #nav-sidebar .module td { 84 | white-space: nowrap; 85 | } 86 | 87 | [dir="rtl"] #nav-sidebar .module th, 88 | [dir="rtl"] #nav-sidebar .module caption { 89 | padding-left: 8px; 90 | padding-right: 16px; 91 | } 92 | 93 | #nav-sidebar .current-app .section:link, 94 | #nav-sidebar .current-app .section:visited { 95 | color: var(--header-color); 96 | font-weight: bold; 97 | } 98 | 99 | #nav-sidebar .current-model { 100 | background: var(--selected-row); 101 | } 102 | 103 | .main > #nav-sidebar + .content { 104 | max-width: calc(100% - 23px); 105 | } 106 | 107 | .main.shifted > #nav-sidebar + .content { 108 | max-width: calc(100% - 299px); 109 | } 110 | 111 | @media (max-width: 767px) { 112 | #nav-sidebar, #toggle-nav-sidebar { 113 | display: none; 114 | } 115 | 116 | .main > #nav-sidebar + .content, 117 | .main.shifted > #nav-sidebar + .content { 118 | max-width: 100%; 119 | } 120 | } 121 | -------------------------------------------------------------------------------- /base/catalog/static/admin/css/responsive_rtl.css: -------------------------------------------------------------------------------- 1 | /* TABLETS */ 2 | 3 | @media (max-width: 1024px) { 4 | [dir="rtl"] .colMS { 5 | margin-right: 0; 6 | } 7 | 8 | [dir="rtl"] #user-tools { 9 | text-align: right; 10 | } 11 | 12 | [dir="rtl"] #changelist .actions label { 13 | padding-left: 10px; 14 | padding-right: 0; 15 | } 16 | 17 | [dir="rtl"] #changelist .actions select { 18 | margin-left: 0; 19 | margin-right: 15px; 20 | } 21 | 22 | [dir="rtl"] .change-list .filtered .results, 23 | [dir="rtl"] .change-list .filtered .paginator, 24 | [dir="rtl"] .filtered #toolbar, 25 | [dir="rtl"] .filtered div.xfull, 26 | [dir="rtl"] .filtered .actions, 27 | [dir="rtl"] #changelist-filter { 28 | margin-left: 0; 29 | } 30 | 31 | [dir="rtl"] .inline-group ul.tools a.add, 32 | [dir="rtl"] .inline-group div.add-row a, 33 | [dir="rtl"] .inline-group .tabular tr.add-row td a { 34 | padding: 8px 26px 8px 10px; 35 | background-position: calc(100% - 8px) 9px; 36 | } 37 | 38 | [dir="rtl"] .related-widget-wrapper-link + .selector { 39 | margin-right: 0; 40 | margin-left: 15px; 41 | } 42 | 43 | [dir="rtl"] .selector .selector-filter label { 44 | margin-right: 0; 45 | margin-left: 8px; 46 | } 47 | 48 | [dir="rtl"] .object-tools li { 49 | float: right; 50 | } 51 | 52 | [dir="rtl"] .object-tools li + li { 53 | margin-left: 0; 54 | margin-right: 15px; 55 | } 56 | 57 | [dir="rtl"] .dashboard .module table td a { 58 | padding-left: 0; 59 | padding-right: 16px; 60 | } 61 | } 62 | 63 | /* MOBILE */ 64 | 65 | @media (max-width: 767px) { 66 | [dir="rtl"] .aligned .related-lookup, 67 | [dir="rtl"] .aligned .datetimeshortcuts { 68 | margin-left: 0; 69 | margin-right: 15px; 70 | } 71 | 72 | [dir="rtl"] .aligned ul { 73 | margin-right: 0; 74 | } 75 | 76 | [dir="rtl"] #changelist-filter { 77 | margin-left: 0; 78 | margin-right: 0; 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /base/catalog/static/admin/css/vendor/select2/LICENSE-SELECT2.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2012-2017 Kevin Brown, Igor Vaynberg, and Select2 contributors 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /base/catalog/static/admin/fonts/README.txt: -------------------------------------------------------------------------------- 1 | Roboto webfont source: https://www.google.com/fonts/specimen/Roboto 2 | WOFF files extracted using https://github.com/majodev/google-webfonts-helper 3 | Weights used in this project: Light (300), Regular (400), Bold (700) 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/fonts/Roboto-Bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/admin/fonts/Roboto-Bold-webfont.woff -------------------------------------------------------------------------------- /base/catalog/static/admin/fonts/Roboto-Light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/admin/fonts/Roboto-Light-webfont.woff -------------------------------------------------------------------------------- /base/catalog/static/admin/fonts/Roboto-Regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/admin/fonts/Roboto-Regular-webfont.woff -------------------------------------------------------------------------------- /base/catalog/static/admin/img/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Code Charm Ltd 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/README.txt: -------------------------------------------------------------------------------- 1 | All icons are taken from Font Awesome (http://fontawesome.io/) project. 2 | The Font Awesome font is licensed under the SIL OFL 1.1: 3 | - https://scripts.sil.org/OFL 4 | 5 | SVG icons source: https://github.com/encharm/Font-Awesome-SVG-PNG 6 | Font-Awesome-SVG-PNG is licensed under the MIT license (see file license 7 | in current folder). 8 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/calendar-icons.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/gis/move_vertex_off.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/gis/move_vertex_on.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-addlink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-alert.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-calendar.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-changelink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-clock.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-deletelink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-no.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-unknown-alt.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-unknown.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-viewlink.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/icon-yes.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/inline-delete.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/search.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/selector-icons.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/sorting-icons.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/tooltag-add.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/img/tooltag-arrowright.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/autocomplete.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const $ = django.jQuery; 4 | const init = function($element, options) { 5 | const settings = $.extend({ 6 | ajax: { 7 | data: function(params) { 8 | return { 9 | term: params.term, 10 | page: params.page, 11 | app_label: $element.data('app-label'), 12 | model_name: $element.data('model-name'), 13 | field_name: $element.data('field-name') 14 | }; 15 | } 16 | } 17 | }, options); 18 | $element.select2(settings); 19 | }; 20 | 21 | $.fn.djangoAdminSelect2 = function(options) { 22 | const settings = $.extend({}, options); 23 | $.each(this, function(i, element) { 24 | const $element = $(element); 25 | init($element, settings); 26 | }); 27 | return this; 28 | }; 29 | 30 | $(function() { 31 | // Initialize all autocomplete widgets except the one in the template 32 | // form used when a new formset is added. 33 | $('.admin-autocomplete').not('[name*=__prefix__]').djangoAdminSelect2(); 34 | }); 35 | 36 | $(document).on('formset:added', (function() { 37 | return function(event, $newFormset) { 38 | return $newFormset.find('.admin-autocomplete').djangoAdminSelect2(); 39 | }; 40 | })(this)); 41 | } 42 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/cancel.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | // Call function fn when the DOM is loaded and ready. If it is already 4 | // loaded, call the function now. 5 | // http://youmightnotneedjquery.com/#ready 6 | function ready(fn) { 7 | if (document.readyState !== 'loading') { 8 | fn(); 9 | } else { 10 | document.addEventListener('DOMContentLoaded', fn); 11 | } 12 | } 13 | 14 | ready(function() { 15 | function handleClick(event) { 16 | event.preventDefault(); 17 | const params = new URLSearchParams(window.location.search); 18 | if (params.has('_popup')) { 19 | window.close(); // Close the popup. 20 | } else { 21 | window.history.back(); // Otherwise, go back. 22 | } 23 | } 24 | 25 | document.querySelectorAll('.cancel-link').forEach(function(el) { 26 | el.addEventListener('click', handleClick); 27 | }); 28 | }); 29 | } 30 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/change_form.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const inputTags = ['BUTTON', 'INPUT', 'SELECT', 'TEXTAREA']; 4 | const modelName = document.getElementById('django-admin-form-add-constants').dataset.modelName; 5 | if (modelName) { 6 | const form = document.getElementById(modelName + '_form'); 7 | for (const element of form.elements) { 8 | // HTMLElement.offsetParent returns null when the element is not 9 | // rendered. 10 | if (inputTags.includes(element.tagName) && !element.disabled && element.offsetParent) { 11 | element.focus(); 12 | break; 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/collapse.js: -------------------------------------------------------------------------------- 1 | /*global gettext*/ 2 | 'use strict'; 3 | { 4 | window.addEventListener('load', function() { 5 | // Add anchor tag for Show/Hide link 6 | const fieldsets = document.querySelectorAll('fieldset.collapse'); 7 | for (const [i, elem] of fieldsets.entries()) { 8 | // Don't hide if fields in this fieldset have errors 9 | if (elem.querySelectorAll('div.errors, ul.errorlist').length === 0) { 10 | elem.classList.add('collapsed'); 11 | const h2 = elem.querySelector('h2'); 12 | const link = document.createElement('a'); 13 | link.id = 'fieldsetcollapser' + i; 14 | link.className = 'collapse-toggle'; 15 | link.href = '#'; 16 | link.textContent = gettext('Show'); 17 | h2.appendChild(document.createTextNode(' (')); 18 | h2.appendChild(link); 19 | h2.appendChild(document.createTextNode(')')); 20 | } 21 | } 22 | // Add toggle to hide/show anchor tag 23 | const toggleFunc = function(ev) { 24 | if (ev.target.matches('.collapse-toggle')) { 25 | ev.preventDefault(); 26 | ev.stopPropagation(); 27 | const fieldset = ev.target.closest('fieldset'); 28 | if (fieldset.classList.contains('collapsed')) { 29 | // Show 30 | ev.target.textContent = gettext('Hide'); 31 | fieldset.classList.remove('collapsed'); 32 | } else { 33 | // Hide 34 | ev.target.textContent = gettext('Show'); 35 | fieldset.classList.add('collapsed'); 36 | } 37 | } 38 | }; 39 | document.querySelectorAll('fieldset.module').forEach(function(el) { 40 | el.addEventListener('click', toggleFunc); 41 | }); 42 | }); 43 | } 44 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/jquery.init.js: -------------------------------------------------------------------------------- 1 | /*global jQuery:false*/ 2 | 'use strict'; 3 | /* Puts the included jQuery into our own namespace using noConflict and passing 4 | * it 'true'. This ensures that the included jQuery doesn't pollute the global 5 | * namespace (i.e. this preserves pre-existing values for both window.$ and 6 | * window.jQuery). 7 | */ 8 | window.django = {jQuery: jQuery.noConflict(true)}; 9 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/nav_sidebar.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const toggleNavSidebar = document.getElementById('toggle-nav-sidebar'); 4 | if (toggleNavSidebar !== null) { 5 | const navLinks = document.querySelectorAll('#nav-sidebar a'); 6 | function disableNavLinkTabbing() { 7 | for (const navLink of navLinks) { 8 | navLink.tabIndex = -1; 9 | } 10 | } 11 | function enableNavLinkTabbing() { 12 | for (const navLink of navLinks) { 13 | navLink.tabIndex = 0; 14 | } 15 | } 16 | 17 | const main = document.getElementById('main'); 18 | let navSidebarIsOpen = localStorage.getItem('django.admin.navSidebarIsOpen'); 19 | if (navSidebarIsOpen === null) { 20 | navSidebarIsOpen = 'true'; 21 | } 22 | if (navSidebarIsOpen === 'false') { 23 | disableNavLinkTabbing(); 24 | } 25 | main.classList.toggle('shifted', navSidebarIsOpen === 'true'); 26 | 27 | toggleNavSidebar.addEventListener('click', function() { 28 | if (navSidebarIsOpen === 'true') { 29 | navSidebarIsOpen = 'false'; 30 | disableNavLinkTabbing(); 31 | } else { 32 | navSidebarIsOpen = 'true'; 33 | enableNavLinkTabbing(); 34 | } 35 | localStorage.setItem('django.admin.navSidebarIsOpen', navSidebarIsOpen); 36 | main.classList.toggle('shifted'); 37 | }); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/popup_response.js: -------------------------------------------------------------------------------- 1 | /*global opener */ 2 | 'use strict'; 3 | { 4 | const initData = JSON.parse(document.getElementById('django-admin-popup-response-constants').dataset.popupResponse); 5 | switch(initData.action) { 6 | case 'change': 7 | opener.dismissChangeRelatedObjectPopup(window, initData.value, initData.obj, initData.new_value); 8 | break; 9 | case 'delete': 10 | opener.dismissDeleteRelatedObjectPopup(window, initData.value); 11 | break; 12 | default: 13 | opener.dismissAddRelatedObjectPopup(window, initData.value, initData.obj); 14 | break; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/prepopulate.js: -------------------------------------------------------------------------------- 1 | /*global URLify*/ 2 | 'use strict'; 3 | { 4 | const $ = django.jQuery; 5 | $.fn.prepopulate = function(dependencies, maxLength, allowUnicode) { 6 | /* 7 | Depends on urlify.js 8 | Populates a selected field with the values of the dependent fields, 9 | URLifies and shortens the string. 10 | dependencies - array of dependent fields ids 11 | maxLength - maximum length of the URLify'd string 12 | allowUnicode - Unicode support of the URLify'd string 13 | */ 14 | return this.each(function() { 15 | const prepopulatedField = $(this); 16 | 17 | const populate = function() { 18 | // Bail if the field's value has been changed by the user 19 | if (prepopulatedField.data('_changed')) { 20 | return; 21 | } 22 | 23 | const values = []; 24 | $.each(dependencies, function(i, field) { 25 | field = $(field); 26 | if (field.val().length > 0) { 27 | values.push(field.val()); 28 | } 29 | }); 30 | prepopulatedField.val(URLify(values.join(' '), maxLength, allowUnicode)); 31 | }; 32 | 33 | prepopulatedField.data('_changed', false); 34 | prepopulatedField.on('change', function() { 35 | prepopulatedField.data('_changed', true); 36 | }); 37 | 38 | if (!prepopulatedField.val()) { 39 | $(dependencies.join(',')).on('keyup change focus', populate); 40 | } 41 | }); 42 | }; 43 | } 44 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/prepopulate_init.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | { 3 | const $ = django.jQuery; 4 | const fields = $('#django-admin-prepopulated-fields-constants').data('prepopulatedFields'); 5 | $.each(fields, function(index, field) { 6 | $('.empty-form .form-row .field-' + field.name + ', .empty-form.form-row .field-' + field.name).addClass('prepopulated_field'); 7 | $(field.id).data('dependency_list', field.dependency_list).prepopulate( 8 | field.dependency_ids, field.maxLength, field.allowUnicode 9 | ); 10 | }); 11 | } 12 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/jquery/LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright JS Foundation and other contributors, https://js.foundation/ 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining 4 | a copy of this software and associated documentation files (the 5 | "Software"), to deal in the Software without restriction, including 6 | without limitation the rights to use, copy, modify, merge, publish, 7 | distribute, sublicense, and/or sell copies of the Software, and to 8 | permit persons to whom the Software is furnished to do so, subject to 9 | the following conditions: 10 | 11 | The above copyright notice and this permission notice shall be 12 | included in all copies or substantial portions of the Software. 13 | 14 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 15 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 16 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 17 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 18 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 19 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 20 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2012-2017 Kevin Brown, Igor Vaynberg, and Select2 contributors 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/af.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/af",[],function(){return{errorLoading:function(){return"Die resultate kon nie gelaai word nie."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Verwyders asseblief "+n+" character";return 1!=n&&(r+="s"),r},inputTooShort:function(e){return"Voer asseblief "+(e.minimum-e.input.length)+" of meer karakters"},loadingMore:function(){return"Meer resultate word gelaai…"},maximumSelected:function(e){var n="Kies asseblief net "+e.maximum+" item";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"Geen resultate gevind"},searching:function(){return"Besig…"},removeAllItems:function(){return"Verwyder alle items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ar.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ar",[],function(){return{errorLoading:function(){return"لا يمكن تحميل النتائج"},inputTooLong:function(n){return"الرجاء حذف "+(n.input.length-n.maximum)+" عناصر"},inputTooShort:function(n){return"الرجاء إضافة "+(n.minimum-n.input.length)+" عناصر"},loadingMore:function(){return"جاري تحميل نتائج إضافية..."},maximumSelected:function(n){return"تستطيع إختيار "+n.maximum+" بنود فقط"},noResults:function(){return"لم يتم العثور على أي نتائج"},searching:function(){return"جاري البحث…"},removeAllItems:function(){return"قم بإزالة كل العناصر"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/az.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/az",[],function(){return{inputTooLong:function(n){return n.input.length-n.maximum+" simvol silin"},inputTooShort:function(n){return n.minimum-n.input.length+" simvol daxil edin"},loadingMore:function(){return"Daha çox nəticə yüklənir…"},maximumSelected:function(n){return"Sadəcə "+n.maximum+" element seçə bilərsiniz"},noResults:function(){return"Nəticə tapılmadı"},searching:function(){return"Axtarılır…"},removeAllItems:function(){return"Bütün elementləri sil"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/bg.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/bg",[],function(){return{inputTooLong:function(n){var e=n.input.length-n.maximum,u="Моля въведете с "+e+" по-малко символ";return e>1&&(u+="a"),u},inputTooShort:function(n){var e=n.minimum-n.input.length,u="Моля въведете още "+e+" символ";return e>1&&(u+="a"),u},loadingMore:function(){return"Зареждат се още…"},maximumSelected:function(n){var e="Можете да направите до "+n.maximum+" ";return n.maximum>1?e+="избора":e+="избор",e},noResults:function(){return"Няма намерени съвпадения"},searching:function(){return"Търсене…"},removeAllItems:function(){return"Премахнете всички елементи"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/bn.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/bn",[],function(){return{errorLoading:function(){return"ফলাফলগুলি লোড করা যায়নি।"},inputTooLong:function(n){var e=n.input.length-n.maximum,u="অনুগ্রহ করে "+e+" টি অক্ষর মুছে দিন।";return 1!=e&&(u="অনুগ্রহ করে "+e+" টি অক্ষর মুছে দিন।"),u},inputTooShort:function(n){return n.minimum-n.input.length+" টি অক্ষর অথবা অধিক অক্ষর লিখুন।"},loadingMore:function(){return"আরো ফলাফল লোড হচ্ছে ..."},maximumSelected:function(n){var e=n.maximum+" টি আইটেম নির্বাচন করতে পারবেন।";return 1!=n.maximum&&(e=n.maximum+" টি আইটেম নির্বাচন করতে পারবেন।"),e},noResults:function(){return"কোন ফলাফল পাওয়া যায়নি।"},searching:function(){return"অনুসন্ধান করা হচ্ছে ..."}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/bs.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/bs",[],function(){function e(e,n,r,t){return e%10==1&&e%100!=11?n:e%10>=2&&e%10<=4&&(e%100<12||e%100>14)?r:t}return{errorLoading:function(){return"Preuzimanje nije uspijelo."},inputTooLong:function(n){var r=n.input.length-n.maximum,t="Obrišite "+r+" simbol";return t+=e(r,"","a","a")},inputTooShort:function(n){var r=n.minimum-n.input.length,t="Ukucajte bar još "+r+" simbol";return t+=e(r,"","a","a")},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(n){var r="Možete izabrati samo "+n.maximum+" stavk";return r+=e(n.maximum,"u","e","i")},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Uklonite sve stavke"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ca.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/ca",[],function(){return{errorLoading:function(){return"La càrrega ha fallat"},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Si us plau, elimina "+n+" car";return r+=1==n?"àcter":"àcters"},inputTooShort:function(e){var n=e.minimum-e.input.length,r="Si us plau, introdueix "+n+" car";return r+=1==n?"àcter":"àcters"},loadingMore:function(){return"Carregant més resultats…"},maximumSelected:function(e){var n="Només es pot seleccionar "+e.maximum+" element";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No s'han trobat resultats"},searching:function(){return"Cercant…"},removeAllItems:function(){return"Treu tots els elements"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/cs.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/cs",[],function(){function e(e,n){switch(e){case 2:return n?"dva":"dvě";case 3:return"tři";case 4:return"čtyři"}return""}return{errorLoading:function(){return"Výsledky nemohly být načteny."},inputTooLong:function(n){var t=n.input.length-n.maximum;return 1==t?"Prosím, zadejte o jeden znak méně.":t<=4?"Prosím, zadejte o "+e(t,!0)+" znaky méně.":"Prosím, zadejte o "+t+" znaků méně."},inputTooShort:function(n){var t=n.minimum-n.input.length;return 1==t?"Prosím, zadejte ještě jeden znak.":t<=4?"Prosím, zadejte ještě další "+e(t,!0)+" znaky.":"Prosím, zadejte ještě dalších "+t+" znaků."},loadingMore:function(){return"Načítají se další výsledky…"},maximumSelected:function(n){var t=n.maximum;return 1==t?"Můžete zvolit jen jednu položku.":t<=4?"Můžete zvolit maximálně "+e(t,!1)+" položky.":"Můžete zvolit maximálně "+t+" položek."},noResults:function(){return"Nenalezeny žádné položky."},searching:function(){return"Vyhledávání…"},removeAllItems:function(){return"Odstraňte všechny položky"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/da.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/da",[],function(){return{errorLoading:function(){return"Resultaterne kunne ikke indlæses."},inputTooLong:function(e){return"Angiv venligst "+(e.input.length-e.maximum)+" tegn mindre"},inputTooShort:function(e){return"Angiv venligst "+(e.minimum-e.input.length)+" tegn mere"},loadingMore:function(){return"Indlæser flere resultater…"},maximumSelected:function(e){var n="Du kan kun vælge "+e.maximum+" emne";return 1!=e.maximum&&(n+="r"),n},noResults:function(){return"Ingen resultater fundet"},searching:function(){return"Søger…"},removeAllItems:function(){return"Fjern alle elementer"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/de.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/de",[],function(){return{errorLoading:function(){return"Die Ergebnisse konnten nicht geladen werden."},inputTooLong:function(e){return"Bitte "+(e.input.length-e.maximum)+" Zeichen weniger eingeben"},inputTooShort:function(e){return"Bitte "+(e.minimum-e.input.length)+" Zeichen mehr eingeben"},loadingMore:function(){return"Lade mehr Ergebnisse…"},maximumSelected:function(e){var n="Sie können nur "+e.maximum+" Element";return 1!=e.maximum&&(n+="e"),n+=" auswählen"},noResults:function(){return"Keine Übereinstimmungen gefunden"},searching:function(){return"Suche…"},removeAllItems:function(){return"Entferne alle Elemente"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/dsb.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/dsb",[],function(){var n=["znamuško","znamušce","znamuška","znamuškow"],e=["zapisk","zapiska","zapiski","zapiskow"],u=function(n,e){return 1===n?e[0]:2===n?e[1]:n>2&&n<=4?e[2]:n>=5?e[3]:void 0};return{errorLoading:function(){return"Wuslědki njejsu se dali zacytaś."},inputTooLong:function(e){var a=e.input.length-e.maximum;return"Pšosym lašuj "+a+" "+u(a,n)},inputTooShort:function(e){var a=e.minimum-e.input.length;return"Pšosym zapódaj nanejmjenjej "+a+" "+u(a,n)},loadingMore:function(){return"Dalšne wuslědki se zacytaju…"},maximumSelected:function(n){return"Móžoš jano "+n.maximum+" "+u(n.maximum,e)+"wubraś."},noResults:function(){return"Žedne wuslědki namakane"},searching:function(){return"Pyta se…"},removeAllItems:function(){return"Remove all items"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/el.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/el",[],function(){return{errorLoading:function(){return"Τα αποτελέσματα δεν μπόρεσαν να φορτώσουν."},inputTooLong:function(n){var e=n.input.length-n.maximum,u="Παρακαλώ διαγράψτε "+e+" χαρακτήρ";return 1==e&&(u+="α"),1!=e&&(u+="ες"),u},inputTooShort:function(n){return"Παρακαλώ συμπληρώστε "+(n.minimum-n.input.length)+" ή περισσότερους χαρακτήρες"},loadingMore:function(){return"Φόρτωση περισσότερων αποτελεσμάτων…"},maximumSelected:function(n){var e="Μπορείτε να επιλέξετε μόνο "+n.maximum+" επιλογ";return 1==n.maximum&&(e+="ή"),1!=n.maximum&&(e+="ές"),e},noResults:function(){return"Δεν βρέθηκαν αποτελέσματα"},searching:function(){return"Αναζήτηση…"},removeAllItems:function(){return"Καταργήστε όλα τα στοιχεία"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/en.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/en",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Please delete "+n+" character";return 1!=n&&(r+="s"),r},inputTooShort:function(e){return"Please enter "+(e.minimum-e.input.length)+" or more characters"},loadingMore:function(){return"Loading more results…"},maximumSelected:function(e){var n="You can only select "+e.maximum+" item";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No results found"},searching:function(){return"Searching…"},removeAllItems:function(){return"Remove all items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/es.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/es",[],function(){return{errorLoading:function(){return"No se pudieron cargar los resultados"},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Por favor, elimine "+n+" car";return r+=1==n?"ácter":"acteres"},inputTooShort:function(e){var n=e.minimum-e.input.length,r="Por favor, introduzca "+n+" car";return r+=1==n?"ácter":"acteres"},loadingMore:function(){return"Cargando más resultados…"},maximumSelected:function(e){var n="Sólo puede seleccionar "+e.maximum+" elemento";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No se encontraron resultados"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Eliminar todos los elementos"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/et.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/et",[],function(){return{inputTooLong:function(e){var n=e.input.length-e.maximum,t="Sisesta "+n+" täht";return 1!=n&&(t+="e"),t+=" vähem"},inputTooShort:function(e){var n=e.minimum-e.input.length,t="Sisesta "+n+" täht";return 1!=n&&(t+="e"),t+=" rohkem"},loadingMore:function(){return"Laen tulemusi…"},maximumSelected:function(e){var n="Saad vaid "+e.maximum+" tulemus";return 1==e.maximum?n+="e":n+="t",n+=" valida"},noResults:function(){return"Tulemused puuduvad"},searching:function(){return"Otsin…"},removeAllItems:function(){return"Eemalda kõik esemed"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/eu.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/eu",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Idatzi ";return n+=1==t?"karaktere bat":t+" karaktere",n+=" gutxiago"},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Idatzi ";return n+=1==t?"karaktere bat":t+" karaktere",n+=" gehiago"},loadingMore:function(){return"Emaitza gehiago kargatzen…"},maximumSelected:function(e){return 1===e.maximum?"Elementu bakarra hauta dezakezu":e.maximum+" elementu hauta ditzakezu soilik"},noResults:function(){return"Ez da bat datorrenik aurkitu"},searching:function(){return"Bilatzen…"},removeAllItems:function(){return"Kendu elementu guztiak"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/fa.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/fa",[],function(){return{errorLoading:function(){return"امکان بارگذاری نتایج وجود ندارد."},inputTooLong:function(n){return"لطفاً "+(n.input.length-n.maximum)+" کاراکتر را حذف نمایید"},inputTooShort:function(n){return"لطفاً تعداد "+(n.minimum-n.input.length)+" کاراکتر یا بیشتر وارد نمایید"},loadingMore:function(){return"در حال بارگذاری نتایج بیشتر..."},maximumSelected:function(n){return"شما تنها می‌توانید "+n.maximum+" آیتم را انتخاب نمایید"},noResults:function(){return"هیچ نتیجه‌ای یافت نشد"},searching:function(){return"در حال جستجو..."},removeAllItems:function(){return"همه موارد را حذف کنید"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/fi.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/fi",[],function(){return{errorLoading:function(){return"Tuloksia ei saatu ladattua."},inputTooLong:function(n){return"Ole hyvä ja anna "+(n.input.length-n.maximum)+" merkkiä vähemmän"},inputTooShort:function(n){return"Ole hyvä ja anna "+(n.minimum-n.input.length)+" merkkiä lisää"},loadingMore:function(){return"Ladataan lisää tuloksia…"},maximumSelected:function(n){return"Voit valita ainoastaan "+n.maximum+" kpl"},noResults:function(){return"Ei tuloksia"},searching:function(){return"Haetaan…"},removeAllItems:function(){return"Poista kaikki kohteet"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/fr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/fr",[],function(){return{errorLoading:function(){return"Les résultats ne peuvent pas être chargés."},inputTooLong:function(e){var n=e.input.length-e.maximum;return"Supprimez "+n+" caractère"+(n>1?"s":"")},inputTooShort:function(e){var n=e.minimum-e.input.length;return"Saisissez au moins "+n+" caractère"+(n>1?"s":"")},loadingMore:function(){return"Chargement de résultats supplémentaires…"},maximumSelected:function(e){return"Vous pouvez seulement sélectionner "+e.maximum+" élément"+(e.maximum>1?"s":"")},noResults:function(){return"Aucun résultat trouvé"},searching:function(){return"Recherche en cours…"},removeAllItems:function(){return"Supprimer tous les éléments"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/gl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/gl",[],function(){return{errorLoading:function(){return"Non foi posíbel cargar os resultados."},inputTooLong:function(e){var n=e.input.length-e.maximum;return 1===n?"Elimine un carácter":"Elimine "+n+" caracteres"},inputTooShort:function(e){var n=e.minimum-e.input.length;return 1===n?"Engada un carácter":"Engada "+n+" caracteres"},loadingMore:function(){return"Cargando máis resultados…"},maximumSelected:function(e){return 1===e.maximum?"Só pode seleccionar un elemento":"Só pode seleccionar "+e.maximum+" elementos"},noResults:function(){return"Non se atoparon resultados"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Elimina todos os elementos"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/he.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/he",[],function(){return{errorLoading:function(){return"שגיאה בטעינת התוצאות"},inputTooLong:function(n){var e=n.input.length-n.maximum,r="נא למחוק ";return r+=1===e?"תו אחד":e+" תווים"},inputTooShort:function(n){var e=n.minimum-n.input.length,r="נא להכניס ";return r+=1===e?"תו אחד":e+" תווים",r+=" או יותר"},loadingMore:function(){return"טוען תוצאות נוספות…"},maximumSelected:function(n){var e="באפשרותך לבחור עד ";return 1===n.maximum?e+="פריט אחד":e+=n.maximum+" פריטים",e},noResults:function(){return"לא נמצאו תוצאות"},searching:function(){return"מחפש…"},removeAllItems:function(){return"הסר את כל הפריטים"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/hi.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hi",[],function(){return{errorLoading:function(){return"परिणामों को लोड नहीं किया जा सका।"},inputTooLong:function(n){var e=n.input.length-n.maximum,r=e+" अक्षर को हटा दें";return e>1&&(r=e+" अक्षरों को हटा दें "),r},inputTooShort:function(n){return"कृपया "+(n.minimum-n.input.length)+" या अधिक अक्षर दर्ज करें"},loadingMore:function(){return"अधिक परिणाम लोड हो रहे है..."},maximumSelected:function(n){return"आप केवल "+n.maximum+" आइटम का चयन कर सकते हैं"},noResults:function(){return"कोई परिणाम नहीं मिला"},searching:function(){return"खोज रहा है..."},removeAllItems:function(){return"सभी वस्तुओं को हटा दें"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/hr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hr",[],function(){function n(n){var e=" "+n+" znak";return n%10<5&&n%10>0&&(n%100<5||n%100>19)?n%10>1&&(e+="a"):e+="ova",e}return{errorLoading:function(){return"Preuzimanje nije uspjelo."},inputTooLong:function(e){return"Unesite "+n(e.input.length-e.maximum)},inputTooShort:function(e){return"Unesite još "+n(e.minimum-e.input.length)},loadingMore:function(){return"Učitavanje rezultata…"},maximumSelected:function(n){return"Maksimalan broj odabranih stavki je "+n.maximum},noResults:function(){return"Nema rezultata"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Ukloni sve stavke"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/hsb.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hsb",[],function(){var n=["znamješko","znamješce","znamješka","znamješkow"],e=["zapisk","zapiskaj","zapiski","zapiskow"],u=function(n,e){return 1===n?e[0]:2===n?e[1]:n>2&&n<=4?e[2]:n>=5?e[3]:void 0};return{errorLoading:function(){return"Wuslědki njedachu so začitać."},inputTooLong:function(e){var a=e.input.length-e.maximum;return"Prošu zhašej "+a+" "+u(a,n)},inputTooShort:function(e){var a=e.minimum-e.input.length;return"Prošu zapodaj znajmjeńša "+a+" "+u(a,n)},loadingMore:function(){return"Dalše wuslědki so začitaja…"},maximumSelected:function(n){return"Móžeš jenož "+n.maximum+" "+u(n.maximum,e)+"wubrać"},noResults:function(){return"Žane wuslědki namakane"},searching:function(){return"Pyta so…"},removeAllItems:function(){return"Remove all items"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/hu.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/hu",[],function(){return{errorLoading:function(){return"Az eredmények betöltése nem sikerült."},inputTooLong:function(e){return"Túl hosszú. "+(e.input.length-e.maximum)+" karakterrel több, mint kellene."},inputTooShort:function(e){return"Túl rövid. Még "+(e.minimum-e.input.length)+" karakter hiányzik."},loadingMore:function(){return"Töltés…"},maximumSelected:function(e){return"Csak "+e.maximum+" elemet lehet kiválasztani."},noResults:function(){return"Nincs találat."},searching:function(){return"Keresés…"},removeAllItems:function(){return"Távolítson el minden elemet"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/hy.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hy",[],function(){return{errorLoading:function(){return"Արդյունքները հնարավոր չէ բեռնել։"},inputTooLong:function(n){return"Խնդրում ենք հեռացնել "+(n.input.length-n.maximum)+" նշան"},inputTooShort:function(n){return"Խնդրում ենք մուտքագրել "+(n.minimum-n.input.length)+" կամ ավել նշաններ"},loadingMore:function(){return"Բեռնվում են նոր արդյունքներ․․․"},maximumSelected:function(n){return"Դուք կարող եք ընտրել առավելագույնը "+n.maximum+" կետ"},noResults:function(){return"Արդյունքներ չեն գտնվել"},searching:function(){return"Որոնում․․․"},removeAllItems:function(){return"Հեռացնել բոլոր տարրերը"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/id.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/id",[],function(){return{errorLoading:function(){return"Data tidak boleh diambil."},inputTooLong:function(n){return"Hapuskan "+(n.input.length-n.maximum)+" huruf"},inputTooShort:function(n){return"Masukkan "+(n.minimum-n.input.length)+" huruf lagi"},loadingMore:function(){return"Mengambil data…"},maximumSelected:function(n){return"Anda hanya dapat memilih "+n.maximum+" pilihan"},noResults:function(){return"Tidak ada data yang sesuai"},searching:function(){return"Mencari…"},removeAllItems:function(){return"Hapus semua item"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/is.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/is",[],function(){return{inputTooLong:function(n){var t=n.input.length-n.maximum,e="Vinsamlegast styttið texta um "+t+" staf";return t<=1?e:e+"i"},inputTooShort:function(n){var t=n.minimum-n.input.length,e="Vinsamlegast skrifið "+t+" staf";return t>1&&(e+="i"),e+=" í viðbót"},loadingMore:function(){return"Sæki fleiri niðurstöður…"},maximumSelected:function(n){return"Þú getur aðeins valið "+n.maximum+" atriði"},noResults:function(){return"Ekkert fannst"},searching:function(){return"Leita…"},removeAllItems:function(){return"Fjarlægðu öll atriði"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/it.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/it",[],function(){return{errorLoading:function(){return"I risultati non possono essere caricati."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Per favore cancella "+n+" caratter";return t+=1!==n?"i":"e"},inputTooShort:function(e){return"Per favore inserisci "+(e.minimum-e.input.length)+" o più caratteri"},loadingMore:function(){return"Caricando più risultati…"},maximumSelected:function(e){var n="Puoi selezionare solo "+e.maximum+" element";return 1!==e.maximum?n+="i":n+="o",n},noResults:function(){return"Nessun risultato trovato"},searching:function(){return"Sto cercando…"},removeAllItems:function(){return"Rimuovi tutti gli oggetti"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ja.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ja",[],function(){return{errorLoading:function(){return"結果が読み込まれませんでした"},inputTooLong:function(n){return n.input.length-n.maximum+" 文字を削除してください"},inputTooShort:function(n){return"少なくとも "+(n.minimum-n.input.length)+" 文字を入力してください"},loadingMore:function(){return"読み込み中…"},maximumSelected:function(n){return n.maximum+" 件しか選択できません"},noResults:function(){return"対象が見つかりません"},searching:function(){return"検索しています…"},removeAllItems:function(){return"すべてのアイテムを削除"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ka.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ka",[],function(){return{errorLoading:function(){return"მონაცემების ჩატვირთვა შეუძლებელია."},inputTooLong:function(n){return"გთხოვთ აკრიფეთ "+(n.input.length-n.maximum)+" სიმბოლოთი ნაკლები"},inputTooShort:function(n){return"გთხოვთ აკრიფეთ "+(n.minimum-n.input.length)+" სიმბოლო ან მეტი"},loadingMore:function(){return"მონაცემების ჩატვირთვა…"},maximumSelected:function(n){return"თქვენ შეგიძლიათ აირჩიოთ არაუმეტეს "+n.maximum+" ელემენტი"},noResults:function(){return"რეზულტატი არ მოიძებნა"},searching:function(){return"ძიება…"},removeAllItems:function(){return"ამოიღე ყველა ელემენტი"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/km.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/km",[],function(){return{errorLoading:function(){return"មិនអាចទាញយកទិន្នន័យ"},inputTooLong:function(n){return"សូមលុបចេញ "+(n.input.length-n.maximum)+" អក្សរ"},inputTooShort:function(n){return"សូមបញ្ចូល"+(n.minimum-n.input.length)+" អក្សរ រឺ ច្រើនជាងនេះ"},loadingMore:function(){return"កំពុងទាញយកទិន្នន័យបន្ថែម..."},maximumSelected:function(n){return"អ្នកអាចជ្រើសរើសបានតែ "+n.maximum+" ជម្រើសប៉ុណ្ណោះ"},noResults:function(){return"មិនមានលទ្ធផល"},searching:function(){return"កំពុងស្វែងរក..."},removeAllItems:function(){return"លុបធាតុទាំងអស់"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ko.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ko",[],function(){return{errorLoading:function(){return"결과를 불러올 수 없습니다."},inputTooLong:function(n){return"너무 깁니다. "+(n.input.length-n.maximum)+" 글자 지워주세요."},inputTooShort:function(n){return"너무 짧습니다. "+(n.minimum-n.input.length)+" 글자 더 입력해주세요."},loadingMore:function(){return"불러오는 중…"},maximumSelected:function(n){return"최대 "+n.maximum+"개까지만 선택 가능합니다."},noResults:function(){return"결과가 없습니다."},searching:function(){return"검색 중…"},removeAllItems:function(){return"모든 항목 삭제"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/lt.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/lt",[],function(){function n(n,e,i,t){return n%10==1&&(n%100<11||n%100>19)?e:n%10>=2&&n%10<=9&&(n%100<11||n%100>19)?i:t}return{inputTooLong:function(e){var i=e.input.length-e.maximum,t="Pašalinkite "+i+" simbol";return t+=n(i,"į","ius","ių")},inputTooShort:function(e){var i=e.minimum-e.input.length,t="Įrašykite dar "+i+" simbol";return t+=n(i,"į","ius","ių")},loadingMore:function(){return"Kraunama daugiau rezultatų…"},maximumSelected:function(e){var i="Jūs galite pasirinkti tik "+e.maximum+" element";return i+=n(e.maximum,"ą","us","ų")},noResults:function(){return"Atitikmenų nerasta"},searching:function(){return"Ieškoma…"},removeAllItems:function(){return"Pašalinti visus elementus"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/lv.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/lv",[],function(){function e(e,n,u,i){return 11===e?n:e%10==1?u:i}return{inputTooLong:function(n){var u=n.input.length-n.maximum,i="Lūdzu ievadiet par "+u;return(i+=" simbol"+e(u,"iem","u","iem"))+" mazāk"},inputTooShort:function(n){var u=n.minimum-n.input.length,i="Lūdzu ievadiet vēl "+u;return i+=" simbol"+e(u,"us","u","us")},loadingMore:function(){return"Datu ielāde…"},maximumSelected:function(n){var u="Jūs varat izvēlēties ne vairāk kā "+n.maximum;return u+=" element"+e(n.maximum,"us","u","us")},noResults:function(){return"Sakritību nav"},searching:function(){return"Meklēšana…"},removeAllItems:function(){return"Noņemt visus vienumus"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/mk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/mk",[],function(){return{inputTooLong:function(n){var e=(n.input.length,n.maximum,"Ве молиме внесете "+n.maximum+" помалку карактер");return 1!==n.maximum&&(e+="и"),e},inputTooShort:function(n){var e=(n.minimum,n.input.length,"Ве молиме внесете уште "+n.maximum+" карактер");return 1!==n.maximum&&(e+="и"),e},loadingMore:function(){return"Вчитување резултати…"},maximumSelected:function(n){var e="Можете да изберете само "+n.maximum+" ставк";return 1===n.maximum?e+="а":e+="и",e},noResults:function(){return"Нема пронајдено совпаѓања"},searching:function(){return"Пребарување…"},removeAllItems:function(){return"Отстрани ги сите предмети"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ms.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ms",[],function(){return{errorLoading:function(){return"Keputusan tidak berjaya dimuatkan."},inputTooLong:function(n){return"Sila hapuskan "+(n.input.length-n.maximum)+" aksara"},inputTooShort:function(n){return"Sila masukkan "+(n.minimum-n.input.length)+" atau lebih aksara"},loadingMore:function(){return"Sedang memuatkan keputusan…"},maximumSelected:function(n){return"Anda hanya boleh memilih "+n.maximum+" pilihan"},noResults:function(){return"Tiada padanan yang ditemui"},searching:function(){return"Mencari…"},removeAllItems:function(){return"Keluarkan semua item"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/nb.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/nb",[],function(){return{errorLoading:function(){return"Kunne ikke hente resultater."},inputTooLong:function(e){return"Vennligst fjern "+(e.input.length-e.maximum)+" tegn"},inputTooShort:function(e){return"Vennligst skriv inn "+(e.minimum-e.input.length)+" tegn til"},loadingMore:function(){return"Laster flere resultater…"},maximumSelected:function(e){return"Du kan velge maks "+e.maximum+" elementer"},noResults:function(){return"Ingen treff"},searching:function(){return"Søker…"},removeAllItems:function(){return"Fjern alle elementer"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ne.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ne",[],function(){return{errorLoading:function(){return"नतिजाहरु देखाउन सकिएन।"},inputTooLong:function(n){var e=n.input.length-n.maximum,u="कृपया "+e+" अक्षर मेटाउनुहोस्।";return 1!=e&&(u+="कृपया "+e+" अक्षरहरु मेटाउनुहोस्।"),u},inputTooShort:function(n){return"कृपया बाँकी रहेका "+(n.minimum-n.input.length)+" वा अरु धेरै अक्षरहरु भर्नुहोस्।"},loadingMore:function(){return"अरु नतिजाहरु भरिँदैछन् …"},maximumSelected:function(n){var e="तँपाई "+n.maximum+" वस्तु मात्र छान्न पाउँनुहुन्छ।";return 1!=n.maximum&&(e="तँपाई "+n.maximum+" वस्तुहरु मात्र छान्न पाउँनुहुन्छ।"),e},noResults:function(){return"कुनै पनि नतिजा भेटिएन।"},searching:function(){return"खोजि हुँदैछ…"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/nl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/nl",[],function(){return{errorLoading:function(){return"De resultaten konden niet worden geladen."},inputTooLong:function(e){return"Gelieve "+(e.input.length-e.maximum)+" karakters te verwijderen"},inputTooShort:function(e){return"Gelieve "+(e.minimum-e.input.length)+" of meer karakters in te voeren"},loadingMore:function(){return"Meer resultaten laden…"},maximumSelected:function(e){var n=1==e.maximum?"kan":"kunnen",r="Er "+n+" maar "+e.maximum+" item";return 1!=e.maximum&&(r+="s"),r+=" worden geselecteerd"},noResults:function(){return"Geen resultaten gevonden…"},searching:function(){return"Zoeken…"},removeAllItems:function(){return"Verwijder alle items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/pl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/pl",[],function(){var n=["znak","znaki","znaków"],e=["element","elementy","elementów"],r=function(n,e){return 1===n?e[0]:n>1&&n<=4?e[1]:n>=5?e[2]:void 0};return{errorLoading:function(){return"Nie można załadować wyników."},inputTooLong:function(e){var t=e.input.length-e.maximum;return"Usuń "+t+" "+r(t,n)},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Podaj przynajmniej "+t+" "+r(t,n)},loadingMore:function(){return"Trwa ładowanie…"},maximumSelected:function(n){return"Możesz zaznaczyć tylko "+n.maximum+" "+r(n.maximum,e)},noResults:function(){return"Brak wyników"},searching:function(){return"Trwa wyszukiwanie…"},removeAllItems:function(){return"Usuń wszystkie przedmioty"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ps.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ps",[],function(){return{errorLoading:function(){return"پايلي نه سي ترلاسه کېدای"},inputTooLong:function(n){var e=n.input.length-n.maximum,r="د مهربانۍ لمخي "+e+" توری ړنګ کړئ";return 1!=e&&(r=r.replace("توری","توري")),r},inputTooShort:function(n){return"لږ تر لږه "+(n.minimum-n.input.length)+" يا ډېر توري وليکئ"},loadingMore:function(){return"نوري پايلي ترلاسه کيږي..."},maximumSelected:function(n){var e="تاسو يوازي "+n.maximum+" قلم په نښه کولای سی";return 1!=n.maximum&&(e=e.replace("قلم","قلمونه")),e},noResults:function(){return"پايلي و نه موندل سوې"},searching:function(){return"لټول کيږي..."},removeAllItems:function(){return"ټول توکي لرې کړئ"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/pt-BR.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/pt-BR",[],function(){return{errorLoading:function(){return"Os resultados não puderam ser carregados."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Apague "+n+" caracter";return 1!=n&&(r+="es"),r},inputTooShort:function(e){return"Digite "+(e.minimum-e.input.length)+" ou mais caracteres"},loadingMore:function(){return"Carregando mais resultados…"},maximumSelected:function(e){var n="Você só pode selecionar "+e.maximum+" ite";return 1==e.maximum?n+="m":n+="ns",n},noResults:function(){return"Nenhum resultado encontrado"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Remover todos os itens"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/pt.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/pt",[],function(){return{errorLoading:function(){return"Os resultados não puderam ser carregados."},inputTooLong:function(e){var r=e.input.length-e.maximum,n="Por favor apague "+r+" ";return n+=1!=r?"caracteres":"caractere"},inputTooShort:function(e){return"Introduza "+(e.minimum-e.input.length)+" ou mais caracteres"},loadingMore:function(){return"A carregar mais resultados…"},maximumSelected:function(e){var r="Apenas pode seleccionar "+e.maximum+" ";return r+=1!=e.maximum?"itens":"item"},noResults:function(){return"Sem resultados"},searching:function(){return"A procurar…"},removeAllItems:function(){return"Remover todos os itens"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ro.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/ro",[],function(){return{errorLoading:function(){return"Rezultatele nu au putut fi incărcate."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Vă rugăm să ștergeți"+t+" caracter";return 1!==t&&(n+="e"),n},inputTooShort:function(e){return"Vă rugăm să introduceți "+(e.minimum-e.input.length)+" sau mai multe caractere"},loadingMore:function(){return"Se încarcă mai multe rezultate…"},maximumSelected:function(e){var t="Aveți voie să selectați cel mult "+e.maximum;return t+=" element",1!==e.maximum&&(t+="e"),t},noResults:function(){return"Nu au fost găsite rezultate"},searching:function(){return"Căutare…"},removeAllItems:function(){return"Eliminați toate elementele"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/ru.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ru",[],function(){function n(n,e,r,u){return n%10<5&&n%10>0&&n%100<5||n%100>20?n%10>1?r:e:u}return{errorLoading:function(){return"Невозможно загрузить результаты"},inputTooLong:function(e){var r=e.input.length-e.maximum,u="Пожалуйста, введите на "+r+" символ";return u+=n(r,"","a","ов"),u+=" меньше"},inputTooShort:function(e){var r=e.minimum-e.input.length,u="Пожалуйста, введите ещё хотя бы "+r+" символ";return u+=n(r,"","a","ов")},loadingMore:function(){return"Загрузка данных…"},maximumSelected:function(e){var r="Вы можете выбрать не более "+e.maximum+" элемент";return r+=n(e.maximum,"","a","ов")},noResults:function(){return"Совпадений не найдено"},searching:function(){return"Поиск…"},removeAllItems:function(){return"Удалить все элементы"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/sk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/sk",[],function(){var e={2:function(e){return e?"dva":"dve"},3:function(){return"tri"},4:function(){return"štyri"}};return{errorLoading:function(){return"Výsledky sa nepodarilo načítať."},inputTooLong:function(n){var t=n.input.length-n.maximum;return 1==t?"Prosím, zadajte o jeden znak menej":t>=2&&t<=4?"Prosím, zadajte o "+e[t](!0)+" znaky menej":"Prosím, zadajte o "+t+" znakov menej"},inputTooShort:function(n){var t=n.minimum-n.input.length;return 1==t?"Prosím, zadajte ešte jeden znak":t<=4?"Prosím, zadajte ešte ďalšie "+e[t](!0)+" znaky":"Prosím, zadajte ešte ďalších "+t+" znakov"},loadingMore:function(){return"Načítanie ďalších výsledkov…"},maximumSelected:function(n){return 1==n.maximum?"Môžete zvoliť len jednu položku":n.maximum>=2&&n.maximum<=4?"Môžete zvoliť najviac "+e[n.maximum](!1)+" položky":"Môžete zvoliť najviac "+n.maximum+" položiek"},noResults:function(){return"Nenašli sa žiadne položky"},searching:function(){return"Vyhľadávanie…"},removeAllItems:function(){return"Odstráňte všetky položky"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/sl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/sl",[],function(){return{errorLoading:function(){return"Zadetkov iskanja ni bilo mogoče naložiti."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Prosim zbrišite "+n+" znak";return 2==n?t+="a":1!=n&&(t+="e"),t},inputTooShort:function(e){var n=e.minimum-e.input.length,t="Prosim vpišite še "+n+" znak";return 2==n?t+="a":1!=n&&(t+="e"),t},loadingMore:function(){return"Nalagam več zadetkov…"},maximumSelected:function(e){var n="Označite lahko največ "+e.maximum+" predmet";return 2==e.maximum?n+="a":1!=e.maximum&&(n+="e"),n},noResults:function(){return"Ni zadetkov."},searching:function(){return"Iščem…"},removeAllItems:function(){return"Odstranite vse elemente"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/sq.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/sq",[],function(){return{errorLoading:function(){return"Rezultatet nuk mund të ngarkoheshin."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Të lutem fshi "+n+" karakter";return 1!=n&&(t+="e"),t},inputTooShort:function(e){return"Të lutem shkruaj "+(e.minimum-e.input.length)+" ose më shumë karaktere"},loadingMore:function(){return"Duke ngarkuar më shumë rezultate…"},maximumSelected:function(e){var n="Mund të zgjedhësh vetëm "+e.maximum+" element";return 1!=e.maximum&&(n+="e"),n},noResults:function(){return"Nuk u gjet asnjë rezultat"},searching:function(){return"Duke kërkuar…"},removeAllItems:function(){return"Hiq të gjitha sendet"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/sr-Cyrl.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/sr-Cyrl",[],function(){function n(n,e,r,u){return n%10==1&&n%100!=11?e:n%10>=2&&n%10<=4&&(n%100<12||n%100>14)?r:u}return{errorLoading:function(){return"Преузимање није успело."},inputTooLong:function(e){var r=e.input.length-e.maximum,u="Обришите "+r+" симбол";return u+=n(r,"","а","а")},inputTooShort:function(e){var r=e.minimum-e.input.length,u="Укуцајте бар још "+r+" симбол";return u+=n(r,"","а","а")},loadingMore:function(){return"Преузимање још резултата…"},maximumSelected:function(e){var r="Можете изабрати само "+e.maximum+" ставк";return r+=n(e.maximum,"у","е","и")},noResults:function(){return"Ништа није пронађено"},searching:function(){return"Претрага…"},removeAllItems:function(){return"Уклоните све ставке"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/sr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/sr",[],function(){function n(n,e,r,t){return n%10==1&&n%100!=11?e:n%10>=2&&n%10<=4&&(n%100<12||n%100>14)?r:t}return{errorLoading:function(){return"Preuzimanje nije uspelo."},inputTooLong:function(e){var r=e.input.length-e.maximum,t="Obrišite "+r+" simbol";return t+=n(r,"","a","a")},inputTooShort:function(e){var r=e.minimum-e.input.length,t="Ukucajte bar još "+r+" simbol";return t+=n(r,"","a","a")},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(e){var r="Možete izabrati samo "+e.maximum+" stavk";return r+=n(e.maximum,"u","e","i")},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Уклоните све ставке"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/sv.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/sv",[],function(){return{errorLoading:function(){return"Resultat kunde inte laddas."},inputTooLong:function(n){return"Vänligen sudda ut "+(n.input.length-n.maximum)+" tecken"},inputTooShort:function(n){return"Vänligen skriv in "+(n.minimum-n.input.length)+" eller fler tecken"},loadingMore:function(){return"Laddar fler resultat…"},maximumSelected:function(n){return"Du kan max välja "+n.maximum+" element"},noResults:function(){return"Inga träffar"},searching:function(){return"Söker…"},removeAllItems:function(){return"Ta bort alla objekt"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/th.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/th",[],function(){return{errorLoading:function(){return"ไม่สามารถค้นข้อมูลได้"},inputTooLong:function(n){return"โปรดลบออก "+(n.input.length-n.maximum)+" ตัวอักษร"},inputTooShort:function(n){return"โปรดพิมพ์เพิ่มอีก "+(n.minimum-n.input.length)+" ตัวอักษร"},loadingMore:function(){return"กำลังค้นข้อมูลเพิ่ม…"},maximumSelected:function(n){return"คุณสามารถเลือกได้ไม่เกิน "+n.maximum+" รายการ"},noResults:function(){return"ไม่พบข้อมูล"},searching:function(){return"กำลังค้นข้อมูล…"},removeAllItems:function(){return"ลบรายการทั้งหมด"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/tk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/tk",[],function(){return{errorLoading:function(){return"Netije ýüklenmedi."},inputTooLong:function(e){return e.input.length-e.maximum+" harp bozuň."},inputTooShort:function(e){return"Ýene-de iň az "+(e.minimum-e.input.length)+" harp ýazyň."},loadingMore:function(){return"Köpräk netije görkezilýär…"},maximumSelected:function(e){return"Diňe "+e.maximum+" sanysyny saýlaň."},noResults:function(){return"Netije tapylmady."},searching:function(){return"Gözlenýär…"},removeAllItems:function(){return"Remove all items"}}}),e.define,e.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/tr.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/tr",[],function(){return{errorLoading:function(){return"Sonuç yüklenemedi"},inputTooLong:function(n){return n.input.length-n.maximum+" karakter daha girmelisiniz"},inputTooShort:function(n){return"En az "+(n.minimum-n.input.length)+" karakter daha girmelisiniz"},loadingMore:function(){return"Daha fazla…"},maximumSelected:function(n){return"Sadece "+n.maximum+" seçim yapabilirsiniz"},noResults:function(){return"Sonuç bulunamadı"},searching:function(){return"Aranıyor…"},removeAllItems:function(){return"Tüm öğeleri kaldır"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/uk.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/uk",[],function(){function n(n,e,u,r){return n%100>10&&n%100<15?r:n%10==1?e:n%10>1&&n%10<5?u:r}return{errorLoading:function(){return"Неможливо завантажити результати"},inputTooLong:function(e){return"Будь ласка, видаліть "+(e.input.length-e.maximum)+" "+n(e.maximum,"літеру","літери","літер")},inputTooShort:function(n){return"Будь ласка, введіть "+(n.minimum-n.input.length)+" або більше літер"},loadingMore:function(){return"Завантаження інших результатів…"},maximumSelected:function(e){return"Ви можете вибрати лише "+e.maximum+" "+n(e.maximum,"пункт","пункти","пунктів")},noResults:function(){return"Нічого не знайдено"},searching:function(){return"Пошук…"},removeAllItems:function(){return"Видалити всі елементи"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/vi.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/vi",[],function(){return{inputTooLong:function(n){return"Vui lòng xóa bớt "+(n.input.length-n.maximum)+" ký tự"},inputTooShort:function(n){return"Vui lòng nhập thêm từ "+(n.minimum-n.input.length)+" ký tự trở lên"},loadingMore:function(){return"Đang lấy thêm kết quả…"},maximumSelected:function(n){return"Chỉ có thể chọn được "+n.maximum+" lựa chọn"},noResults:function(){return"Không tìm thấy kết quả"},searching:function(){return"Đang tìm…"},removeAllItems:function(){return"Xóa tất cả các mục"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/zh-CN.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/zh-CN",[],function(){return{errorLoading:function(){return"无法载入结果。"},inputTooLong:function(n){return"请删除"+(n.input.length-n.maximum)+"个字符"},inputTooShort:function(n){return"请再输入至少"+(n.minimum-n.input.length)+"个字符"},loadingMore:function(){return"载入更多结果…"},maximumSelected:function(n){return"最多只能选择"+n.maximum+"个项目"},noResults:function(){return"未找到结果"},searching:function(){return"搜索中…"},removeAllItems:function(){return"删除所有项目"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/select2/i18n/zh-TW.js: -------------------------------------------------------------------------------- 1 | /*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ 2 | 3 | !function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/zh-TW",[],function(){return{inputTooLong:function(n){return"請刪掉"+(n.input.length-n.maximum)+"個字元"},inputTooShort:function(n){return"請再輸入"+(n.minimum-n.input.length)+"個字元"},loadingMore:function(){return"載入中…"},maximumSelected:function(n){return"你只能選擇最多"+n.maximum+"項"},noResults:function(){return"沒有找到相符的項目"},searching:function(){return"搜尋中…"},removeAllItems:function(){return"刪除所有項目"}}}),n.define,n.require}(); -------------------------------------------------------------------------------- /base/catalog/static/admin/js/vendor/xregexp/LICENSE.txt: -------------------------------------------------------------------------------- 1 | The MIT License 2 | 3 | Copyright (c) 2007-2017 Steven Levithan 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /base/catalog/static/css/catalog.css: -------------------------------------------------------------------------------- 1 | @charset "UTF-8"; 2 | 3 | 4 | /* backgrounds: */ 5 | .br-risk-critical { 6 | background-color: #cc0a78; 7 | } 8 | 9 | .bg-risk-high { 10 | background-color: #ff3385; 11 | } 12 | 13 | .bg-risk-high a:link { 14 | color: #000000; 15 | } 16 | 17 | .bg-risk-high a:visited { 18 | color: #ff99c2; 19 | } 20 | 21 | .bg-risk-high a:active, .bg-risk-high a:hover { 22 | color: #f0f0f0 23 | } 24 | 25 | .bg-risk-medium { 26 | background-color:#df9fbf; 27 | } 28 | 29 | .bg-risk-medium a:link { 30 | color: #000000; 31 | } 32 | 33 | .bg-risk-medium a:visited { 34 | color: #ffe6f2; 35 | } 36 | 37 | .bg-risk-medium a:active, .bg-risk-medium a:hover { 38 | color: #f0f0f0 39 | } 40 | 41 | .bg-risk-low { 42 | background-color:#ffeb99; 43 | } 44 | 45 | .bg-risk-low a:link { 46 | color: #000000; 47 | } 48 | 49 | .bg-risk-low a:visited { 50 | color: #ffffe6; 51 | } 52 | 53 | .bg-risk-low a:active, .bg-risk-low a:hover { 54 | color: #ffffff; 55 | } 56 | 57 | .bg-risk-solved { 58 | background-color:#00e673; 59 | } 60 | /* End of backgrounds */ 61 | 62 | .bg-risk-solved a:link { 63 | color: #ffffff; 64 | } 65 | 66 | .bg-risk-solved a:visited { 67 | color: #ccffcc; 68 | } 69 | 70 | .bg-risk-solved a:active, .bg-risk-low a:hover { 71 | color: #ffffff; 72 | } 73 | 74 | /* tables: */ 75 | .tr-faded { 76 | color:#D3D3D3; /* HTML color name: LightGrey */ 77 | background-color:#FFFFFF; /* HTML color name: White */ 78 | } 79 | 80 | .tr-faded-warning { 81 | background-color:#FFFFE0; /* HTML color name: LightYellow */ 82 | } 83 | 84 | .table-bg-smoke { 85 | background-color:#F5F5F5; /* HTML color name: WhiteSmoke */ 86 | } 87 | /* End of tables */ 88 | -------------------------------------------------------------------------------- /base/catalog/static/cvss/identity/cvss_web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/cvss/identity/cvss_web.png -------------------------------------------------------------------------------- /base/catalog/static/django_tinymce/init_tinymce.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | { 4 | function initTinyMCE(el) { 5 | if (el.closest('.empty-form') === null) { // Don't do empty inlines 6 | var mce_conf = JSON.parse(el.dataset.mceConf); 7 | 8 | // There is no way to pass a JavaScript function as an option 9 | // because all options are serialized as JSON. 10 | const fns = [ 11 | 'color_picker_callback', 12 | 'file_browser_callback', 13 | 'file_picker_callback', 14 | 'images_dataimg_filter', 15 | 'images_upload_handler', 16 | 'paste_postprocess', 17 | 'paste_preprocess', 18 | 'setup', 19 | 'urlconverter_callback', 20 | ]; 21 | fns.forEach((fn_name) => { 22 | if (typeof mce_conf[fn_name] != 'undefined') { 23 | if (mce_conf[fn_name].includes('(')) { 24 | mce_conf[fn_name] = eval('(' + mce_conf[fn_name] + ')'); 25 | } 26 | else { 27 | mce_conf[fn_name] = window[mce_conf[fn_name]]; 28 | } 29 | } 30 | }); 31 | 32 | const id = el.id; 33 | if ('elements' in mce_conf && mce_conf['mode'] == 'exact') { 34 | mce_conf['elements'] = id; 35 | } 36 | if (el.dataset.mceGzConf) { 37 | tinyMCE_GZ.init(JSON.parse(el.dataset.mceGzConf)); 38 | } 39 | if (!tinyMCE.editors[id]) { 40 | tinyMCE.init(mce_conf); 41 | } 42 | } 43 | } 44 | 45 | // Call function fn when the DOM is loaded and ready. If it is already 46 | // loaded, call the function now. 47 | // http://youmightnotneedjquery.com/#ready 48 | function ready(fn) { 49 | if (document.readyState !== 'loading') { 50 | fn(); 51 | } else { 52 | document.addEventListener('DOMContentLoaded', fn); 53 | } 54 | } 55 | 56 | ready(function() { 57 | // initialize the TinyMCE editors on load 58 | document.querySelectorAll('.tinymce').forEach(function(el) { 59 | initTinyMCE(el); 60 | }); 61 | 62 | // initialize the TinyMCE editor after adding an inline in the django admin context. 63 | if (typeof(django) !== 'undefined' && typeof(django.jQuery) !== 'undefined') { 64 | django.jQuery(document).on('formset:added', function(event, $row, formsetName) { 65 | $row.find('textarea.tinymce').each(function() { 66 | initTinyMCE(this); 67 | }); 68 | }); 69 | } 70 | }); 71 | } 72 | -------------------------------------------------------------------------------- /base/catalog/static/imgs/artifacts/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/imgs/artifacts/favicon.png -------------------------------------------------------------------------------- /base/catalog/static/imgs/cvss/identity/cvss_web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/imgs/cvss/identity/cvss_web.png -------------------------------------------------------------------------------- /base/catalog/static/js/bootstrap.min.js.map: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/daavelino/vulnerability-catalog/61e0db9cc4656a16847ec635a4cac3e9a6c67dd4/base/catalog/static/js/bootstrap.min.js.map -------------------------------------------------------------------------------- /base/catalog/static/tinymce/custom.js: -------------------------------------------------------------------------------- 1 | tinymce.init({ 2 | selector: 'textarea', 3 | plugins: 'image code', 4 | toolbar: 'undo redo | link image | code', 5 | /* enable title field in the Image dialog*/ 6 | image_title: true, 7 | /* enable automatic uploads of images represented by blob or data URIs*/ 8 | automatic_uploads: true, 9 | /* 10 | URL of our upload handler (for more details check: https://www.tiny.cloud/docs/configure/file-image-upload/#images_upload_url) 11 | images_upload_url: 'postAcceptor.php', 12 | here we add custom filepicker only to Image dialog 13 | */ 14 | file_picker_types: 'image', 15 | /* and here's our custom image picker*/ 16 | file_picker_callback: function (cb, value, meta) { 17 | var input = document.createElement('input'); 18 | input.setAttribute('type', 'file'); 19 | input.setAttribute('accept', 'image/*'); 20 | 21 | /* 22 | Note: In modern browsers input[type="file"] is functional without 23 | even adding it to the DOM, but that might not be the case in some older 24 | or quirky browsers like IE, so you might want to add it to the DOM 25 | just in case, and visually hide it. And do not forget do remove it 26 | once you do not need it anymore. 27 | */ 28 | 29 | input.onchange = function () { 30 | var file = this.files[0]; 31 | 32 | var reader = new FileReader(); 33 | reader.onload = function () { 34 | /* 35 | Note: Now we need to register the blob in TinyMCEs image blob 36 | registry. In the next release this part hopefully won't be 37 | necessary, as we are looking to handle it internally. 38 | */ 39 | var id = 'blobid' + (new Date()).getTime(); 40 | var blobCache = tinymce.activeEditor.editorUpload.blobCache; 41 | var base64 = reader.result.split(',')[1]; 42 | var blobInfo = blobCache.create(id, file, base64); 43 | blobCache.add(blobInfo); 44 | 45 | /* call the callback and populate the Title field with the file name */ 46 | cb(blobInfo.blobUri(), { title: file.name }); 47 | }; 48 | reader.readAsDataURL(file); 49 | }; 50 | 51 | input.click(); 52 | } 53 | }); 54 | -------------------------------------------------------------------------------- /base/catalog/static/tinymce/langs/readme.md: -------------------------------------------------------------------------------- 1 | This is where language files should be placed. 2 | 3 | Please DO NOT translate these directly use this service: https://www.transifex.com/projects/p/tinymce/ 4 | -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/advlist/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(){"use strict";var n,t,e,r,u=tinymce.util.Tools.resolve("tinymce.PluginManager"),v=tinymce.util.Tools.resolve("tinymce.util.Tools"),O=function(n,t,e){var r="UL"===t?"InsertUnorderedList":"InsertOrderedList";n.execCommand(r,!1,!1===e?null:{"list-style-type":e})},o=function(e){e.addCommand("ApplyUnorderedListStyle",function(n,t){O(e,"UL",t["list-style-type"])}),e.addCommand("ApplyOrderedListStyle",function(n,t){O(e,"OL",t["list-style-type"])})},i=function(n){var t=n.getParam("advlist_number_styles","default,lower-alpha,lower-greek,lower-roman,upper-alpha,upper-roman");return t?t.split(/[ ,]/):[]},l=function(n){var t=n.getParam("advlist_bullet_styles","default,circle,square");return t?t.split(/[ ,]/):[]},c=function(n){return function(){return n}},s=c(!1),f=c(!0),a=s,d=f,g=function(){return p},p=(r={fold:function(n,t){return n()},is:a,isSome:a,isNone:d,getOr:e=function(n){return n},getOrThunk:t=function(n){return n()},getOrDie:function(n){throw new Error(n||"error: getOrDie called on none.")},getOrNull:function(){return null},getOrUndefined:function(){return undefined},or:e,orThunk:t,map:g,ap:g,each:function(){},bind:g,flatten:g,exists:a,forall:d,filter:g,equals:n=function(n){return n.isNone()},equals_:n,toArray:function(){return[]},toString:c("none()")},Object.freeze&&Object.freeze(r),r),m=function(e){var n=function(){return e},t=function(){return u},r=function(n){return n(e)},u={fold:function(n,t){return t(e)},is:function(n){return e===n},isSome:d,isNone:a,getOr:n,getOrThunk:n,getOrDie:n,getOrNull:n,getOrUndefined:n,or:t,orThunk:t,map:function(n){return m(n(e))},ap:function(n){return n.fold(g,function(n){return m(n(e))})},each:function(n){n(e)},bind:r,flatten:n,exists:r,forall:r,filter:function(n){return n(e)?u:p},equals:function(n){return n.is(e)},equals_:function(n,t){return n.fold(a,function(n){return t(e,n)})},toArray:function(){return[e]},toString:function(){return"some("+e+")"}};return u},y=function(n){return null===n||n===undefined?p:m(n)},h=function(n){return n&&/^(TH|TD)$/.test(n.nodeName)},L=function(r){return function(n){return n&&/^(OL|UL|DL)$/.test(n.nodeName)&&(e=n,(t=r).$.contains(t.getBody(),e));var t,e}},N=function(n){var t=n.dom.getParent(n.selection.getNode(),"ol,ul"),e=n.dom.getStyle(t,"listStyleType");return y(e)},S=function(n,t,e){var r=function(n,t){for(var e=0;ev(e)&&(i=o+l);var m=y(e);m&&m]*>((\xa0| |[ \t]|]*>)+?|)|
$","i").test(e)},f=function(t){var e=parseInt(a.getItem(s(t)+"time"),10)||0;return!((new Date).getTime()-e>u(t.settings.autosave_retention,"20m"))||(l(t,!1),!1)},l=function(t,e){var r=s(t);a.removeItem(r+"draft"),a.removeItem(r+"time"),!1!==e&&t.fire("RemoveDraft")},m=function(t){var e=s(t);!c(t)&&t.isDirty()&&(a.setItem(e+"draft",t.getContent({format:"raw",no_events:!0})),a.setItem(e+"time",(new Date).getTime().toString()),t.fire("StoreDraft"))},v=function(t){var e=s(t);f(t)&&(t.setContent(a.getItem(e+"draft"),{format:"raw"}),t.fire("RestoreDraft"))},d=function(t,e){var r=u(t.settings.autosave_interval,"30s");e.get()||(n.setInterval(function(){t.removed||m(t)},r),e.set(!0))},g=function(t){t.undoManager.transact(function(){v(t),l(t)}),t.focus()};function y(n){for(var o=[],t=1;t(.*?)<\/a>/gi,"[url=$1]$2[/url]"),o(/(.*?)<\/font>/gi,"[code][color=$1]$2[/color][/code]"),o(/(.*?)<\/font>/gi,"[quote][color=$1]$2[/color][/quote]"),o(/(.*?)<\/font>/gi,"[code][color=$1]$2[/color][/code]"),o(/(.*?)<\/font>/gi,"[quote][color=$1]$2[/color][/quote]"),o(/(.*?)<\/span>/gi,"[color=$1]$2[/color]"),o(/(.*?)<\/font>/gi,"[color=$1]$2[/color]"),o(/(.*?)<\/span>/gi,"[size=$1]$2[/size]"),o(/(.*?)<\/font>/gi,"$1"),o(//gi,"[img]$1[/img]"),o(/(.*?)<\/span>/gi,"[code]$1[/code]"),o(/(.*?)<\/span>/gi,"[quote]$1[/quote]"),o(/(.*?)<\/strong>/gi,"[code][b]$1[/b][/code]"),o(/(.*?)<\/strong>/gi,"[quote][b]$1[/b][/quote]"),o(/(.*?)<\/em>/gi,"[code][i]$1[/i][/code]"),o(/(.*?)<\/em>/gi,"[quote][i]$1[/i][/quote]"),o(/(.*?)<\/u>/gi,"[code][u]$1[/u][/code]"),o(/(.*?)<\/u>/gi,"[quote][u]$1[/u][/quote]"),o(/<\/(strong|b)>/gi,"[/b]"),o(/<(strong|b)>/gi,"[b]"),o(/<\/(em|i)>/gi,"[/i]"),o(/<(em|i)>/gi,"[i]"),o(/<\/u>/gi,"[/u]"),o(/(.*?)<\/span>/gi,"[u]$1[/u]"),o(//gi,"[u]"),o(/]*>/gi,"[quote]"),o(/<\/blockquote>/gi,"[/quote]"),o(/
/gi,"\n"),o(//gi,"\n"),o(/
/gi,"\n"),o(/

/gi,""),o(/<\/p>/gi,"\n"),o(/ |\u00a0/gi," "),o(/"/gi,'"'),o(/</gi,"<"),o(/>/gi,">"),o(/&/gi,"&"),t},i=function(t){t=e.trim(t);var o=function(o,e){t=t.replace(o,e)};return o(/\n/gi,"
"),o(/\[b\]/gi,""),o(/\[\/b\]/gi,""),o(/\[i\]/gi,""),o(/\[\/i\]/gi,""),o(/\[u\]/gi,""),o(/\[\/u\]/gi,""),o(/\[url=([^\]]+)\](.*?)\[\/url\]/gi,'$2'),o(/\[url\](.*?)\[\/url\]/gi,'$1'),o(/\[img\](.*?)\[\/img\]/gi,''),o(/\[color=(.*?)\](.*?)\[\/color\]/gi,'$2'),o(/\[code\](.*?)\[\/code\]/gi,'$1 '),o(/\[quote.*?\](.*?)\[\/quote\]/gi,'$1 '),t};!function n(){o.add("bbcode",function(o){o.on("BeforeSetContent",function(o){o.content=i(o.content)}),o.on("PostProcess",function(o){o.set&&(o.content=i(o.content)),o.get&&(o.content=t(o.content))})})}()}(); -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/code/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(){"use strict";var e=tinymce.util.Tools.resolve("tinymce.PluginManager"),t=function(e,n){e.focus(),e.undoManager.transact(function(){e.setContent(n)}),e.selection.setCursorLocation(),e.nodeChanged()},o=function(e){return e.getContent({source_view:!0})},n=function(n){var e=o(n);n.windowManager.open({title:"Source Code",size:"large",body:{type:"panel",items:[{type:"textarea",name:"code"}]},buttons:[{type:"cancel",name:"cancel",text:"Cancel"},{type:"submit",name:"save",text:"Save",primary:!0}],initialData:{code:e},onSubmit:function(e){t(n,e.getData().code),e.close()}})},c=function(e){e.addCommand("mceCodeEditor",function(){n(e)})},i=function(e){e.ui.registry.addButton("code",{icon:"sourcecode",tooltip:"Source code",onAction:function(){return n(e)}}),e.ui.registry.addMenuItem("code",{icon:"sourcecode",text:"Source code",onAction:function(){return n(e)}})};!function u(){e.add("code",function(e){return c(e),i(e),{}})}()}(); -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/colorpicker/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(o){"use strict";var i=tinymce.util.Tools.resolve("tinymce.PluginManager");!function n(){i.add("colorpicker",function(){o.console.warn("Color picker plugin is now built in to the core editor, please remove it from your editor configuration")})}()}(window); -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/contextmenu/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(n){"use strict";var o=tinymce.util.Tools.resolve("tinymce.PluginManager");!function e(){o.add("contextmenu",function(){n.console.warn("Context menu plugin is now built in to the core editor, please remove it from your editor configuration")})}()}(window); -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/directionality/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(c){"use strict";var n,t,e,r,o=tinymce.util.Tools.resolve("tinymce.PluginManager"),u=tinymce.util.Tools.resolve("tinymce.util.Tools"),i=function(n,t){var e,r=n.dom,o=n.selection.getSelectedBlocks();o.length&&(e=r.getAttrib(o[0],"dir"),u.each(o,function(n){r.getParent(n.parentNode,'*[dir="'+t+'"]',r.getRoot())||r.setAttrib(n,"dir",e!==t?t:null)}),n.nodeChanged())},f=function(n){n.addCommand("mceDirectionLTR",function(){i(n,"ltr")}),n.addCommand("mceDirectionRTL",function(){i(n,"rtl")})},d=function(n){return function(){return n}},l=d(!1),a=d(!0),N=l,m=a,s=function(){return T},T=(r={fold:function(n,t){return n()},is:N,isSome:N,isNone:m,getOr:e=function(n){return n},getOrThunk:t=function(n){return n()},getOrDie:function(n){throw new Error(n||"error: getOrDie called on none.")},getOrNull:function(){return null},getOrUndefined:function(){return undefined},or:e,orThunk:t,map:s,ap:s,each:function(){},bind:s,flatten:s,exists:N,forall:m,filter:s,equals:n=function(n){return n.isNone()},equals_:n,toArray:function(){return[]},toString:d("none()")},Object.freeze&&Object.freeze(r),r),g=function(e){var n=function(){return e},t=function(){return o},r=function(n){return n(e)},o={fold:function(n,t){return t(e)},is:function(n){return e===n},isSome:m,isNone:N,getOr:n,getOrThunk:n,getOrDie:n,getOrNull:n,getOrUndefined:n,or:t,orThunk:t,map:function(n){return g(n(e))},ap:function(n){return n.fold(s,function(n){return g(n(e))})},each:function(n){n(e)},bind:r,flatten:n,exists:r,forall:r,filter:function(n){return n(e)?o:T},equals:function(n){return n.is(e)},equals_:function(n,t){return n.fold(N,function(n){return t(e,n)})},toArray:function(){return[e]},toString:function(){return"some("+e+")"}};return o},O=function(n){return null===n||n===undefined?T:g(n)},E=function(n){if(null===n||n===undefined)throw new Error("Node cannot be null or undefined");return{dom:d(n)}},y={fromHtml:function(n,t){var e=(t||c.document).createElement("div");if(e.innerHTML=n,!e.hasChildNodes()||1")})},t=function(n){n.ui.registry.addButton("hr",{icon:"horizontal-rule",tooltip:"Horizontal line",onAction:function(){return n.execCommand("InsertHorizontalRule")}}),n.ui.registry.addMenuItem("hr",{icon:"horizontal-rule",text:"Horizontal line",onAction:function(){return n.execCommand("InsertHorizontalRule")}})};!function e(){n.add("hr",function(n){o(n),t(n)})}()}(); -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/insertdatetime/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(){"use strict";var e=tinymce.util.Tools.resolve("tinymce.PluginManager"),n=function(e){return e.getParam("insertdatetime_timeformat",e.translate("%H:%M:%S"))},r=function(e){return e.getParam("insertdatetime_formats",["%H:%M:%S","%Y-%m-%d","%I:%M:%S %p","%D"])},t=function(e){return e.getParam("insertdatetime_dateformat",e.translate("%Y-%m-%d"))},a=n,i=r,o=function(e){var t=r(e);return 0'+n+"")}else e.insertContent(f(e,t));var i,o,u,c,m},g=f,y=function(e){e.addCommand("mceInsertDate",function(){p(e,t(e))}),e.addCommand("mceInsertTime",function(){p(e,a(e))})},M=tinymce.util.Tools.resolve("tinymce.util.Tools"),S=function(e){var t=e,n=function(){return t};return{get:n,set:function(e){t=e},clone:function(){return S(n())}}},v=function(n){var t=i(n),r=S(o(n));n.ui.registry.addSplitButton("insertdatetime",{icon:"insert-time",tooltip:"Insert date/time",select:function(e){return e===r.get()},fetch:function(e){e(M.map(t,function(e){return{type:"choiceitem",text:g(n,e),value:e}}))},onAction:function(){for(var e=[],t=0;t ':" ";n.insertContent(function(n,e){for(var o="",t=0;t"===r){var a=o.lastIndexOf("<",e);if(-1!==a)if(-1!==o.substring(a,e).indexOf('contenteditable="false"'))return t}return''+i.dom.encode("string"==typeof n[1]?n[1]:n[0])+""}},n=function(n){var t,e,r="contenteditable";t=" "+c.trim(u(n))+" ",e=" "+c.trim(l(n))+" ";var a=s(t),i=s(e),o=f(n);n.on("PreInit",function(){0'},o=function(o){var c=a(o),n=new RegExp(c.replace(/[\?\.\*\[\]\(\)\{\}\+\^\$\:]/g,function(e){return"\\"+e}),"gi");o.on("BeforeSetContent",function(e){e.content=e.content.replace(n,r())}),o.on("PreInit",function(){o.serializer.addNodeFilter("img",function(e){for(var n,a,t=e.length;t--;)if((a=(n=e[t]).attr("class"))&&-1!==a.indexOf("mce-pagebreak")){var r=n.parent;if(o.schema.getBlockElements()[r.name]&&i(o)){r.type=3,r.value=c,r.raw=!0,n.remove();continue}n.type=3,n.value=c,n.raw=!0}})})},c=r,u=t,g=function(e){e.addCommand("mcePageBreak",function(){e.settings.pagebreak_split_block?e.insertContent("

"+c()+"

"):e.insertContent(c())})},m=function(n){n.on("ResolveName",function(e){"IMG"===e.target.nodeName&&n.dom.hasClass(e.target,u())&&(e.name="pagebreak")})},s=function(e){e.ui.registry.addButton("pagebreak",{icon:"page-break",tooltip:"Page break",onAction:function(){return e.execCommand("mcePageBreak")}}),e.ui.registry.addMenuItem("pagebreak",{text:"Page break",icon:"page-break",onAction:function(){return e.execCommand("mcePageBreak")}})};!function l(){e.add("pagebreak",function(e){g(e),s(e),o(e),m(e)})}()}(); -------------------------------------------------------------------------------- /base/catalog/static/tinymce/plugins/preview/plugin.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Tiny Technologies, Inc. All rights reserved. 3 | * Licensed under the LGPL or a commercial license. 4 | * For LGPL see License.txt in the project root for license information. 5 | * For commercial licenses see https://www.tiny.cloud/ 6 | * 7 | * Version: 5.0.8 (2019-06-18) 8 | */ 9 | !function(){"use strict";var e=tinymce.util.Tools.resolve("tinymce.PluginManager"),d=tinymce.util.Tools.resolve("tinymce.util.Tools"),l=function(e){return e.getParam("content_style","")},m=function(e){return e.getParam("content_css_cors",!1,"boolean")},i=function(t){var n="",i=t.dom.encode,e=l(t);n+='',e&&(n+='");var o=m(t)?' crossorigin="anonymous"':"";d.each(t.contentCSS,function(e){n+='"});var r=t.settings.body_id||"tinymce";-1!==r.indexOf("=")&&(r=(r=t.getParam("body_id","","hash"))[t.id]||r);var a=t.settings.body_class||"";-1!==a.indexOf("=")&&(a=(a=t.getParam("body_class","","hash"))[t.id]||"");var c=t.getBody().dir,s=c?' dir="'+i(c)+'"':"";return""+n+'"+t.getContent()+' 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 31 | 32 |
33 | 34 |
35 |
36 | {% csrf_token %} 37 | 38 | {{ form }} 39 |
40 |
41 | 42 | {% if next %} 43 | 44 | {% endif %} 45 |
46 | 47 | {% block footer %}{% endblock %} 48 |
49 | 50 | 51 | 52 | -------------------------------------------------------------------------------- /base/catalog/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /base/catalog/uploadFileViews.py: -------------------------------------------------------------------------------- 1 | from json import loads as JSONLoads 2 | from gzip import compress 3 | from base64 import b64encode 4 | 5 | from django.contrib.auth.decorators import login_required, permission_required 6 | from django.contrib.contenttypes.models import ContentType 7 | from django.contrib.sessions.models import Session 8 | from django.db import transaction 9 | from django.db.utils import DatabaseError 10 | from django.http import HttpRequest, HttpResponse 11 | from django.http import HttpResponseForbidden, HttpResponseRedirect 12 | from django.shortcuts import render 13 | from django.urls import reverse 14 | from django.utils.decorators import method_decorator 15 | from django.views.generic import TemplateView 16 | 17 | from .models import Vulnerability, RiskQuestions 18 | 19 | 20 | login_url='catalog:login' 21 | success_url='catalog:index' 22 | decorators = [login_required(login_url='catalog:login')] 23 | 24 | def recoverData(modelName, data): 25 | ''' 26 | Recover data from JSON data to given model. 27 | Returns a base64 gzipped list string of all 28 | object saved ids, or None otherwise. 29 | ''' 30 | model_fields = modelName._meta.get_fields() 31 | model_name_str = str(modelName._meta) 32 | allowed_fields = [i.name for i in model_fields] 33 | fields = list() 34 | created_list = list() 35 | delete_list = list() 36 | tmp_list = list() 37 | 38 | json_data = JSONLoads(data) 39 | for i in json_data: 40 | if i['model'] == model_name_str: 41 | tmp = i['fields'] 42 | if set(tmp.keys()) > set(allowed_fields): 43 | return None 44 | else: 45 | fields.append(tmp) 46 | 47 | for i in fields: 48 | model_data = modelName(**i) 49 | tmp_list.append(model_data) 50 | 51 | created_list = modelName.objects.bulk_create(tmp_list) 52 | for i in created_list: 53 | delete_list.append(str(i.id)) 54 | 55 | delete_list = ','.join(delete_list) 56 | delete_list = compress(bytes(delete_list, 'utf-8')) 57 | delete_list = b64encode(delete_list) 58 | delete_list = delete_list.decode('utf-8') 59 | 60 | return delete_list 61 | 62 | 63 | @method_decorator(decorators, name='dispatch') 64 | @method_decorator(permission_required('catalog.add_vulnerability', \ 65 | raise_exception=True), name='dispatch') 66 | class MassiveUpload(TemplateView): 67 | ''' /catalog/vulnerability/data/json/massiveupload/ ''' 68 | model = Vulnerability 69 | template_name = 'catalog/upload.html' 70 | 71 | def uploadData(HttpRequest): 72 | template_name = 'catalog/upload.html' 73 | #### Unfortunately, decorators do not work here: 74 | if not HttpRequest.user.is_authenticated: 75 | return HttpResponseRedirect(reverse(login_url)) 76 | if not HttpRequest.user.has_perm('catalog.add_vulnerability'): 77 | return HttpResponseForbidden('

403 Forbidden

') 78 | 79 | try: 80 | f = HttpRequest.FILES['uploadedFile'] 81 | savePreview = HttpRequest.POST.get('savePreview') 82 | previewTime = HttpRequest.POST.get('previewTime') 83 | if savePreview is None: 84 | savePreview = 'False' 85 | if previewTime is None: 86 | previewTime = 0 87 | except: 88 | return render(HttpRequest, template_name, {'uploaderror': True}) 89 | try: 90 | data = f.read() 91 | JSONLoads(data) # Checks if data is JSON'nable'. 92 | except: 93 | return render(HttpRequest, template_name, {'uploaderror': True}) 94 | 95 | result = recoverData(Vulnerability, data) 96 | 97 | if result is None: 98 | return render(HttpRequest, \ 99 | template_name, \ 100 | {'uploaderror': True}) 101 | else: 102 | return render(HttpRequest, template_name, \ 103 | { 'uploaderror':False, 104 | 'savepoint':result}) 105 | 106 | -------------------------------------------------------------------------------- /base/catalog/urls.py: -------------------------------------------------------------------------------- 1 | from django.urls import include, path 2 | from catalog.admin import admin_site 3 | from django.contrib.auth import logout 4 | from django.conf import settings 5 | 6 | from . import views 7 | 8 | app_name="catalog" 9 | 10 | urlpatterns = [ 11 | path('', views.HomeView.as_view(), name='home'), 12 | path('accounts/login/', views.LoginView.as_view(), name='login'), 13 | path('accounts/logout/', views.LogoutView.logout_user, name='logout'), 14 | path('admin/', admin_site.urls), 15 | path('panorama/', views.PanoramaView.as_view(), name='panorama'), 16 | path('resources/upload/getfile/', views.MassiveUpload.uploadData, name='getUploadFile'), 17 | path('resources/data/converter/', views.DataConverter.as_view(), name='converter'), 18 | path('vulnerability/add/', views.AddVulnerability.as_view(), name='addVulnerability'), 19 | path('vulnerability/data/deleteall/', views.RemoveAllVulnerabilities.removeData), 20 | path('vulnerability/data/json/export/', views.JsonExportView.export_database, name='exportData'), 21 | path('vulnerability/data/json/filter/', views.JsonFilterView.get_data, name='jsonfilter'), 22 | path('vulnerability/data/index', views.IndexView.as_view(), name='index'), 23 | path('vulnerability/data/json//', views.JsonDetailView.result), 24 | path('vulnerability/data/json/massiveupload/', views.MassiveUpload.as_view(), name='massiveUpload'), 25 | path('vulnerability/data/panorama/json/', views.PanoramaJsonView.result), 26 | path('vulnerability/delete//', views.DeleteVulnerability.as_view(), name='deleteVulnerability'), 27 | path('vulnerability/data/delete/', views.DeleteByList.as_view(), name='deleteByList'), 28 | path('vulnerability/detail//', views.DetailedView.as_view(), name='detail'), 29 | path('vulnerability/detail/json//', views.JsonDetailView.result, name='json_detail'), 30 | path('vulnerability/search/', views.SearchView.search, name='search'), 31 | path('vulnerability/update/fastupdate//', views.FastUpdateVulnerability.as_view(), name='fastUpdateVulnerability'), 32 | path('vulnerability/update//', views.UpdateVulnerability.as_view(), name='updateVulnerability'), 33 | path('vulnerability/tinymce/', include('tinymce.urls')), 34 | ] 35 | 36 | -------------------------------------------------------------------------------- /base/catalog/views.py: -------------------------------------------------------------------------------- 1 | #### It is just an index to the other views: 2 | 3 | from .authViews import LoginView, LogoutView 4 | from .crudViews import AddVulnerability, \ 5 | DeleteVulnerability, \ 6 | DetailedView, \ 7 | FastUpdateVulnerability, \ 8 | HomeView, \ 9 | IndexView, \ 10 | PanoramaView, \ 11 | UpdateVulnerability, \ 12 | RemoveAllVulnerabilities, \ 13 | DeleteByList 14 | from .dataConverterViews import DataConverter 15 | from .dataViews import PanoramaJsonView, JsonFilterView, JsonDetailView 16 | from .exportViews import JsonExportView 17 | from .searchViews import SearchView 18 | from .uploadFileViews import MassiveUpload 19 | -------------------------------------------------------------------------------- /base/manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | """Django's command-line utility for administrative tasks.""" 3 | import os 4 | import sys 5 | 6 | 7 | def main(): 8 | """Run administrative tasks.""" 9 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'base.settings') 10 | try: 11 | from django.core.management import execute_from_command_line 12 | except ImportError as exc: 13 | raise ImportError( 14 | "Couldn't import Django. Are you sure it's installed and " 15 | "available on your PYTHONPATH environment variable? Did you " 16 | "forget to activate a virtual environment?" 17 | ) from exc 18 | execute_from_command_line(sys.argv) 19 | 20 | 21 | if __name__ == '__main__': 22 | main() 23 | -------------------------------------------------------------------------------- /base/run_cherrypy.py: -------------------------------------------------------------------------------- 1 | 2 | from base.wsgi import application 3 | import cherrypy 4 | import sys 5 | 6 | 7 | if __name__ == '__main__': 8 | 9 | 10 | hostname = "0.0.0.0" 11 | port = 8000 12 | 13 | if len(sys.argv) == 2: 14 | tmp = sys.argv[1].split(":") 15 | if len(tmp) == 2: 16 | hostname = tmp[0] 17 | port = int(tmp[1]) 18 | 19 | 20 | # Mount the application 21 | cherrypy.tree.graft(application, "/") 22 | 23 | # Unsubscribe the default server 24 | cherrypy.server.unsubscribe() 25 | 26 | # Instantiate a new server object 27 | server = cherrypy._cpserver.Server() 28 | 29 | # Configure the server object 30 | server.socket_host = hostname 31 | server.socket_port = port 32 | server.thread_pool = 30 33 | 34 | # For SSL Support 35 | # server.ssl_module = 'builtin' 36 | # server.ssl_certificate = 'ssl/certificate.cer' 37 | # server.ssl_private_key = 'ssl/private.key' 38 | # server.ssl_certificate_chain = 'ssl/bundle.pem' 39 | 40 | # Subscribe this server 41 | server.subscribe() 42 | 43 | # Start the server engine 44 | 45 | cherrypy.engine.start() 46 | cherrypy.engine.block() 47 | 48 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | django 2 | django-tinymce 3 | whitenoise 4 | cherrypy 5 | -------------------------------------------------------------------------------- /run.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | ADDRESS="" 4 | if [[ $1 ]]; then 5 | ADDRESS=$1 6 | fi 7 | if [[ -d ./venv ]]; then 8 | source venv/bin/activate 9 | 10 | fi 11 | cd base 12 | python run_cherrypy.py $ADDRESS 13 | cd .. 14 | -------------------------------------------------------------------------------- /setup.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | HOME=$(pwd) 4 | 5 | if [[ -d ./venv ]]; then 6 | source venv/bin/activate 7 | else 8 | python -m venv venv 9 | source venv/bin/activate 10 | fi 11 | 12 | pip install -r requirements.txt 13 | 14 | secret_key=$(python tools/genSessionKey.py) 15 | sed -i -e "s/__SECRET_KEY__/${secret_key}/" base/base/settings.py 16 | 17 | cd base 18 | python manage.py makemigrations 19 | python manage.py migrate 20 | python manage.py loaddata catalog/fixturename/riskQuestions-example.json 21 | python manage.py createsuperuser 22 | 23 | cd $HOME 24 | -------------------------------------------------------------------------------- /test/data/data-sm.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "model": "catalog.vulnerability", 4 | "fields": { 5 | "system": "Web Supply", 6 | "owner": "Niels Bohr", 7 | "owner_email": "bohr@copenhagen.com", 8 | "environment": "Cloud", 9 | "perimeter": "External", 10 | "technology": "ASPX", 11 | "system_type": "Application", 12 | "vulnerability": "File structure exposed", 13 | "synopsis": "/wp-includes exposed.", 14 | "cvss_value": 4, 15 | "identification_date": "2018-01-28", 16 | "remediation_deadline": "2018-02-28", 17 | "status": "Notified" 18 | } 19 | }, 20 | { 21 | "model": "catalog.vulnerability", 22 | "fields": { 23 | "system": "Sharepoint Interno", 24 | "owner": "Niels Bohr", 25 | "owner_email": "bohr@copenhagen.com", 26 | "environment": "Data Center", 27 | "perimeter": "Internal", 28 | "technology": "Sharepoint Microsoft", 29 | "system_type": "Application", 30 | "vulnerability": "Sensitive data exposure", 31 | "category": "Unprotected Comunication", 32 | "synopsis": "Authentication tokens transported without criptographic protection.", 33 | "cvss_value": 8, 34 | "identification_date": "2018-01-28", 35 | "reporter": "Consulting", 36 | "risk": "Medium", 37 | "observation": "User's credentials are sent in plaintext (without cryptographic protection) to the applications.", 38 | "remediation": "Server was configured to use TLS in all its communications.", 39 | "risk_acceptance_reason": "", 40 | "remediation_deadline": "2018-02-28", 41 | "status": "Notified", 42 | "report_file": "Consulting - 28.01.2018 - External Test Report - V.1.0.docx", 43 | "report_page": 19 44 | } 45 | } 46 | ] 47 | -------------------------------------------------------------------------------- /test/data/riskQuestions-example.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "model": "catalog.riskquestions", 4 | "pk": 1, 5 | "fields": { 6 | "position": 0, 7 | "question": "From the correct exploitation of the vulnerability, business should expect: (Keep in mind the simplest possibility of exploitation.)", 8 | "question_shortname": "Header", 9 | "weight": 1 10 | } 11 | }, 12 | { 13 | "model": "catalog.riskquestions", 14 | "pk": 2, 15 | "fields": { 16 | "position": 1, 17 | "question": "Volume of business information prone to becoming out of control:", 18 | "question_shortname": "BI", 19 | "weight": 1 20 | } 21 | }, 22 | { 23 | "model": "catalog.riskquestions", 24 | "pk": 3, 25 | "fields": { 26 | "position": 2, 27 | "question": "Business functions threatened of interruption due to the vulnerability exploitation:", 28 | "question_shortname": "BF", 29 | "weight": 1 30 | } 31 | }, 32 | { 33 | "model": "catalog.riskquestions", 34 | "pk": 4, 35 | "fields": { 36 | "position": 3, 37 | "question": "Strategic business information at risk due to the vulnerability:", 38 | "question_shortname": "SI", 39 | "weight": 1 40 | } 41 | }, 42 | { 43 | "model": "catalog.riskquestions", 44 | "pk": 5, 45 | "fields": { 46 | "position": 4, 47 | "question": "Legal or regulatory penalties due to the vulnerability:", 48 | "question_shortname":"LR", 49 | "weight": 1 50 | } 51 | }, 52 | { 53 | "model": "catalog.riskquestions", 54 | "pk": 6, 55 | "fields": { 56 | "position": 5, 57 | "question": "The estimated effort to remove the vulnerability:", 58 | "question_shortname":"EE", 59 | "weight": 1 60 | } 61 | } 62 | ] 63 | -------------------------------------------------------------------------------- /test/tools/testDataGenerator.py: -------------------------------------------------------------------------------- 1 | import json 2 | import random 3 | import string 4 | import sys 5 | 6 | 7 | def randomString(size): 8 | alphabet = string.ascii_letters + string.digits + ' ' 9 | size = int(size) 10 | return ''.join([random.choice(alphabet) for n in range(size)]) 11 | 12 | def randomDate(): 13 | year = str(random.randint(2018, 2020)) 14 | month = str(random.randint(1, 12)).rjust(2, "0") 15 | day = str(random.randint(1, 28)).rjust(2, "0") 16 | 17 | return year + "-" + month + "-" + day 18 | 19 | def randomPicker(target): 20 | ''' 21 | Returns a random element from a given 'target' list. 22 | ''' 23 | return target[random.randint(0, len(target)-1)] 24 | 25 | risk = [ 26 | 'Critical',\ 27 | 'High',\ 28 | 'Medium',\ 29 | 'Low',\ 30 | 'Not identified' 31 | ] 32 | perimeter = [ 33 | 'External',\ 34 | 'Internal' 35 | ] 36 | status = [ 37 | 'Mitigated',\ 38 | 'Not identified',\ 39 | 'Notified',\ 40 | 'Risk accepted',\ 41 | 'Solved'] 42 | owner = [ 43 | 'Beatrix Kiddo',\ 44 | 'Bill',\ 45 | 'Budd',\ 46 | 'Elle Driver',\ 47 | 'Hattori Hanzo',\ 48 | 'Sofie Fatale',\ 49 | 'O-Ren Ishii',\ 50 | 'Vernitta Green' 51 | ] 52 | system = [ 53 | 'system 01', 54 | 'system 02', 55 | 'system 03', 56 | 'system 04', 57 | 'system 05', 58 | 'system 06', 59 | 'system 07', 60 | 'system 08', 61 | 'system 09', 62 | 'system 10', 63 | 'system 11', 64 | 'system 12', 65 | 'system 13', 66 | 'system 14', 67 | 'system 15', 68 | 'system 16', 69 | 'system 17', 70 | 'system 18', 71 | 'system 19', 72 | 'system 20', 73 | ] 74 | category = [ 75 | 'cat 01','cat 02','cat 03','cat 04','cat 05','cat 06','cat 07','cat 08','cat 09','cat 10', \ 76 | 'cat 11','cat 12','cat 13','cat 14','cat 15','cat 16','cat 17','cat 18','cat 19','cat 20', \ 77 | 'cat 21','cat 22','cat 23','cat 24','cat 25','cat 26','cat 27','cat 28','cat 29','cat 30', \ 78 | 'cat 31','cat 32','cat 33','cat 34','cat 35','cat 36','cat 37','cat 38','cat 39','cat 40', \ 79 | 'cat 41','cat 42','cat 43','cat 44','cat 45','cat 46','cat 47','cat 48','cat 49','cat 50' 80 | ] 81 | 82 | def generateEntries(): 83 | vulnerability = { 84 | "model": "catalog.vulnerability", 85 | "fields": { 86 | "system": randomPicker(system), 87 | "owner": randomPicker(owner), 88 | "owner_email": randomString(8) + '@' + randomString(3) + '.com', 89 | "environment": randomString(8), 90 | "perimeter": randomPicker(perimeter), 91 | "technology": randomString(8), 92 | "system_type": randomString(8), 93 | "vulnerability": randomString(16), 94 | "category": randomPicker(category), 95 | "synopsis": randomString(64), 96 | "cvss_value": random.randint(0,10), 97 | "identification_date": randomDate(), 98 | "reporter": "Catalog Random Data Generator.", 99 | "risk": randomPicker(risk), 100 | "observation": randomString(64), 101 | "remediation": "", 102 | "remediation_deadline": randomDate(), 103 | "status": randomPicker(status), 104 | "report_file": "N/A", 105 | "report_page": 0 106 | } 107 | } 108 | 109 | return(vulnerability) 110 | 111 | if __name__=='__main__': 112 | 113 | if len(sys.argv) != 2: 114 | sys.stdout.write('Usage: ' + sys.argv[0] + ' \n') 115 | sys.exit(1) 116 | else: 117 | number = int(sys.argv[1]) 118 | output_file = "../data/random-data-" + str(number) + '-entries.json' 119 | sys.stdout.write('Generating ' + str(number) + ' test entries.\n') 120 | result = list() 121 | 122 | for i in range(0, number): 123 | result.append(generateEntries()) 124 | 125 | result = json.dumps(result) 126 | 127 | f = open(output_file, 'w') 128 | f.write(result) 129 | f.close() 130 | 131 | sys.stdout.write('Done. Check ' + output_file + ' file.\n') 132 | sys.exit(0) 133 | -------------------------------------------------------------------------------- /tools/deployDocker.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | cd .. 4 | docker rm -f vcContainer 5 | docker rmi -f vulnerability-catalog 6 | docker build -t vulnerability-catalog . 7 | docker run -it --name vcContainer -p 8000:8000 vulnerability-catalog 8 | -------------------------------------------------------------------------------- /tools/genSessionKey.py: -------------------------------------------------------------------------------- 1 | import secrets 2 | 3 | def genkey(size): 4 | key = secrets.token_hex(size) 5 | return key 6 | 7 | 8 | if __name__=="__main__": 9 | size = 64 10 | key = genkey(size) 11 | print(key) 12 | --------------------------------------------------------------------------------