diff --git a/cgi-bin/malp.rb b/cgi-bin/malp.rb index e567133..82212f2 100755 --- a/cgi-bin/malp.rb +++ b/cgi-bin/malp.rb @@ -61,7 +61,8 @@ if cgi.request_method == "POST" && !authenticated if check_credentials(username, password) token = create_session cookie = CGI::Cookie.new("name" => "MALP", "value" => token, "path" => "/") - authenticated = true + print cgi.header("Status" => "303 See Other", "Location" => ENV["REQUEST_URI"], "cookie" => cookie) + exit end end