mirror of
https://github.com/neocities/neocities.git
synced 2025-07-20 09:36:00 +02:00
remove scrypt, update ext gems, fix legal info doc
This commit is contained in:
parent
3da57195c6
commit
45834176c1
4 changed files with 12 additions and 23 deletions
|
@ -310,7 +310,6 @@ class Site < Sequel::Model
|
|||
return false if ENV['RACK_ENV'] == 'production' && ip == '127.0.0.1'
|
||||
return false if ip.blank?
|
||||
return true if Site.where(is_banned: true).
|
||||
where(ip: [ip, hash_ip(ip)]).
|
||||
where(['updated_at > ?', Time.now-BANNED_TIME]).
|
||||
first
|
||||
|
||||
|
@ -319,10 +318,6 @@ class Site < Sequel::Model
|
|||
false
|
||||
end
|
||||
|
||||
def hash_ip(ip)
|
||||
SCrypt::Engine.hash_secret ip, $config['ip_hash_salt']
|
||||
end
|
||||
|
||||
def ssl_sites
|
||||
select(:id, :username, :domain, :ssl_key, :ssl_cert).
|
||||
exclude(domain: nil).
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue