Private
Public Access
1
0

some fixes, honeypot registration

This commit is contained in:
2025-08-13 10:31:03 +02:00
parent 909aa2013e
commit 781321eadd
5 changed files with 68 additions and 4 deletions

View File

@@ -895,6 +895,14 @@ def rower_register_view(request):
nextpage = '/rowers/list-workouts/'
if request.method == 'POST':
# Check if honeypot was triggered (optional logging)
honeypot_value = request.POST.get('url', '')
if honeypot_value:
# bot user, do not register
messages.error(request, "Registration failed. Please try again.")
url = reverse('rower_register_view')
return HttpResponseRedirect(url)
form = RegistrationFormSex(request.POST)
if form.is_valid():
first_name = form.cleaned_data['first_name']