Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

typo in hsts variable

  • Loading branch information...
commit a94bde0cf2f6b7b6611219935f995519290c79e0 1 parent c3079c8
@mkristian authored
View
1  enforce-ssl-gem/Mavenfile
@@ -1 +0,0 @@
-properties['jruby.plugins.version'] = '0.26.0-SNAPSHOT'
View
2  enforce-ssl-gem/enforce-ssl.gemspec
@@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = 'enforce-ssl'
- s.version = '0.3.0'
+ s.version = '0.2.2'
s.summary = 'enforce the use of SSL for all controller actions'
s.description = 'enforce the use of SSL for all controller actions, skip the enforcement with skip_before_filter :enforce_ssl for selected actions. moto: secure everything, open where needed'
View
17 enforce-ssl-gem/enforce-ssl.gemspec.pom
@@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>rubygems</groupId>
<artifactId>enforce-ssl</artifactId>
- <version>0.3.0</version>
+ <version>0.2.2</version>
<name><![CDATA[enforce the use of SSL for all controller actions]]></name>
<packaging>gem</packaging>
<description><![CDATA[enforce the use of SSL for all controller actions, skip the enforcement with skip_before_filter :enforce_ssl for selected actions. moto: secure everything, open where needed]]></description>
@@ -27,18 +27,6 @@
<url>http://gems.saumya.de/releases</url>
</repository>
</repositories>
- <pluginRepositories>
- <pluginRepository>
- <id>sonatype-snapshots</id>
- <url>http://oss.sonatype.org/content/repositories/snapshots</url>
- <releases>
- <enabled>false</enabled>
- </releases>
- <snapshots>
- <enabled>true</enabled>
- </snapshots>
- </pluginRepository>
- </pluginRepositories>
<dependencies>
<dependency>
<groupId>rubygems</groupId>
@@ -51,12 +39,13 @@
<groupId>org.jruby</groupId>
<artifactId>jruby-complete</artifactId>
<version>1.5.6</version>
+ <type>jar</type>
</dependency>
</dependencies>
<properties>
<gem.home>${project.build.directory}/rubygems</gem.home>
<gem.path>${project.build.directory}/rubygems</gem.path>
- <jruby.plugins.version>0.26.0-SNAPSHOT</jruby.plugins.version>
+ <jruby.plugins.version>0.26.0</jruby.plugins.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
View
2  enforce-ssl-gem/lib/enforce_ssl/enforce_ssl_filter.rb
@@ -13,7 +13,7 @@ def enforce_ssl
# use only if max_age is set and only in production mode since it
# needs a proper (not self-signed) certificate
if Rails.configuration.hsts_max_age && Rails.env == "production"
- subdomain = Rails.configuration.hsts_include_sub_domains? ? " ; includeSubDomains" : ""
+ subdomain = Rails.configuration.hsts_include_sub_domain == true ? " ; includeSubDomains" : ""
controller. response.headers['Strict-Transport-Security'] = "max-age=#{Rails.configuration.hsts_max_age.to_i}" + subdomain
end
View
2  enforce-ssl-gem/lib/enforce_ssl/enforce_ssl_rack.rb
@@ -17,7 +17,7 @@ def call(env)
# use only if max_age is set and only in production mode since it
# needs a proper (not self-signed) certificate
if Rails.configuration.hsts_max_age && Rails.env == "production"
- subdomain = Rails.configuration.hsts_include_sub_domains? ? " ; includeSubDomains" : ""
+ subdomain = Rails.configuration.hsts_include_sub_domain == true ? " ; includeSubDomains" : ""
@headers['Strict-Transport-Security'] = "max-age=#{Rails.configuration.hsts_max_age.to_i}" + subdomain
end
Please sign in to comment.
Something went wrong with that request. Please try again.