aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/force_ssl_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Remove tests method for test cases when controller can be inferred.Guo Xiang2014-05-031-14/+1
|
* Add support for extra options to `force_ssl`Andrew White2013-04-251-14/+106
| | | | | | | | This commit adds support for passing additional url options along with a :status option and any of the flash-related options to `redirect_to` (i.e. :flash, :alert & :notice). Closes #7570.
* Use `request.fullpath` to build redirect url in `force_ssl`Andrew White2013-04-251-0/+63
| | | | | | | | | | | The `force_ssl` command now builds the redirect url from `request.fullpath`. This ensures that the format is maintained and it doesn't redirect to a route that has the same parameters but is defined earlier in `routes.rb`. Also any optional segments are maintained. Fixes #7528. Fixes #9061. Fixes #10305.
* Extracted redirect logic from ActionController::Force::ClassMethods.force_sslJeremy Friesen2012-05-311-0/+31
| | | | | | | | | | | | | Prior to this patch the existing .force_ssl method handles both defining the filter and handling the logic for performing the redirect. With this patch the logic for redirecting to the HTTPS protocol is separated from the filter logic that determines if a redirect should occur. By separating the two levels of behavior, an instance method for ActionController (i.e. #force_ssl_redirect) is exposed and available for more granular SSL enforcement. Cleaned up indentation.
* Tests :if option of force_ssl methodAlexey Vakhov2012-04-011-0/+23
|
* SSL should not be disabled by default in any environment.Pat Allan2012-02-231-14/+0
|
* Fixed force_ssl redirects to include original query paramsRyan McGeary2012-02-071-0/+6
| | | | | | | | | | `ActionController.force_ssl` redirects http URLs to their https equivalent; however, when a URL contains a query string, the resulting redirect lacked the original query string. Conflicts: actionpack/lib/action_controller/metal/force_ssl.rb
* Use performed? instead of checking for response_bodyCarlos Antonio da Silva2012-01-191-3/+0
| | | | | | * Check for performed? instead of response_body * Change performed? to return a boolean * Refactor AC::Metal#response_body= to reuse variable
* When force redirecting to SSL, make sure that the session is kept. As we're ↵Marcin Bunsch and Przemek Dąbek2012-01-121-1/+37
| | | | moving from a non-secure to secure environment, it's safe
* accept optional :host parameter to force_sslBen Scheirman2011-10-081-1/+21
|
* Add controller-specific `force_ssl` method to force web browser to use HTTPS ↵Prem Sichanugrist2011-03-281-0/+83
protocol This would become useful for site which sometime transferring sensitive information such as account information on particular controller or action. This featured was requested by DHH.