Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
“Hzllaga” committed Feb 25, 2020
1 parent 9d23ffe commit 1ced277
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
XSS Hunter修改版,文章:[XSS Hunter平台搭建记录](https://wtfsec.org/posts/xss-hunter%E5%B9%B3%E5%8F%B0%E6%90%AD%E5%BB%BA%E8%AE%B0%E5%BD%95/)
# XSS Hunter修改版,文章:[XSS Hunter平台搭建记录](https://wtfsec.org/posts/xss-hunter%E5%B9%B3%E5%8F%B0%E6%90%AD%E5%BB%BA%E8%AE%B0%E5%BD%95/)

# XSS Hunter Source Code

Expand Down
4 changes: 2 additions & 2 deletions api/apiserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ def validate_input( self, required_field_list, input_dict ):

def validate_recaptcha( self, recaptcha_response, ip ):
if recaptcha_response == "":
self.error( "Missing required field recaptcha")
self.error( "Invalid CAPTCHA")
return False
URIReCaptcha = 'https://www.google.com/recaptcha/api/siteverify'
recaptchaResponse = recaptcha_response
Expand All @@ -144,7 +144,7 @@ def validate_recaptcha( self, recaptcha_response, ip ):
result = json.loads(data)
success = result.get('success', None)
if success == False:
self.error( "Recaptcha response error")
self.error( "Invalid CAPTCHA")
return False
return True

Expand Down
2 changes: 1 addition & 1 deletion gui/static/js/register.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function register_account() {
localStorage.setItem( "CSRF_TOKEN", CSRF_TOKEN );
window.location = "/app";
} else {
$( ".bad_signup_text_fields" ).text( response["invalid_fields"] );
$( ".bad_signup_text_fields" ).text( response["error"] );
if( $( ".bad_signup_text_fields" ).text().indexOf( "Invalid CAPTCHA" ) > -1 || $( ".bad_signup_text_fields" ).text().indexOf( "Invite code not valid" ) > -1 ) {
grecaptcha.reset();
}
Expand Down

0 comments on commit 1ced277

Please sign in to comment.