first commit
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
This commit is contained in:
0
django/CVE-2021-35042/web/vuln/__init__.py
Normal file
0
django/CVE-2021-35042/web/vuln/__init__.py
Normal file
6
django/CVE-2021-35042/web/vuln/apps.py
Normal file
6
django/CVE-2021-35042/web/vuln/apps.py
Normal file
@@ -0,0 +1,6 @@
|
||||
from django.apps import AppConfig
|
||||
|
||||
|
||||
class VulnConfig(AppConfig):
|
||||
name = 'vuln'
|
||||
default_auto_field = 'django.db.models.BigAutoField'
|
21
django/CVE-2021-35042/web/vuln/migrations/0001_initial.py
Normal file
21
django/CVE-2021-35042/web/vuln/migrations/0001_initial.py
Normal file
@@ -0,0 +1,21 @@
|
||||
# Generated by Django 3.1.4 on 2021-07-05 11:59
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
initial = True
|
||||
|
||||
dependencies = [
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Collection',
|
||||
fields=[
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=128)),
|
||||
],
|
||||
),
|
||||
]
|
7
django/CVE-2021-35042/web/vuln/models.py
Normal file
7
django/CVE-2021-35042/web/vuln/models.py
Normal file
@@ -0,0 +1,7 @@
|
||||
from django.db import models
|
||||
|
||||
# Create your models here.
|
||||
|
||||
|
||||
class Collection(models.Model):
|
||||
name = models.CharField(max_length=128)
|
7
django/CVE-2021-35042/web/vuln/urls.py
Normal file
7
django/CVE-2021-35042/web/vuln/urls.py
Normal file
@@ -0,0 +1,7 @@
|
||||
from django.urls import include, path, re_path
|
||||
from . import views
|
||||
|
||||
|
||||
urlpatterns = [
|
||||
path('vuln/', views.vul),
|
||||
]
|
10
django/CVE-2021-35042/web/vuln/views.py
Normal file
10
django/CVE-2021-35042/web/vuln/views.py
Normal file
@@ -0,0 +1,10 @@
|
||||
from django.shortcuts import HttpResponse
|
||||
from .models import Collection
|
||||
|
||||
# Create your views here.
|
||||
|
||||
|
||||
def vul(request):
|
||||
query = request.GET.get('order', default='id')
|
||||
q = Collection.objects.order_by(query)
|
||||
return HttpResponse(q.values())
|
Reference in New Issue
Block a user