Skip to content

Commit

Permalink
Update views.py
Browse files Browse the repository at this point in the history
no code smell
  • Loading branch information
PavelLinearB authored May 18, 2023
1 parent 74c9bd9 commit 50ad828
Showing 1 changed file with 1 addition and 54 deletions.
55 changes: 1 addition & 54 deletions introduction/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,60 +132,7 @@ def xss_lab3(request):
else:
return redirect('login')

#***********************************SQL****************************************************************#

#def sql(request):
# if request.user.is_authenticated:
#
# return render(request,'Lab/SQL/sql.html')
# else:
# return redirect('login')
#
#def sql_lab(request):
# if request.user.is_authenticated:
#
# name=request.POST.get('name')
#
# password=request.POST.get('pass')
#
# if name:
#
# if login.objects.filter(user=name):
#
# sql_query = "SELECT * FROM introduction_login WHERE user='"+name+"'AND password='"+password+"'"
# print(sql_query)
# try:
# print("\nin try\n")
# val=login.objects.raw(sql_query)
# except:
# print("\nin except\n")
# return render(
# request,
# 'Lab/SQL/sql_lab.html',
# {
# "wrongpass":password,
# "sql_error":sql_query
# })
#
# if val:
# user=val[0].user
# return render(request, 'Lab/SQL/sql_lab.html',{"user1":user})
# else:
# return render(
# request,
# 'Lab/SQL/sql_lab.html',
# {
# "wrongpass":password,
# "sql_error":sql_query
# })
# else:
# return render(request, 'Lab/SQL/sql_lab.html',{"no": "User not found"})
# else:
# return render(request, 'Lab/SQL/sql_lab.html')
# else:
# return redirect('login')

#***************** INSECURE DESERIALIZATION***************************************************************#


def insec_des(request):
if request.user.is_authenticated:
Expand Down

0 comments on commit 50ad828

Please sign in to comment.