Loading .gitignore +0 −1 Original line number Diff line number Diff line Loading @@ -11,7 +11,6 @@ app/assets/images/custom/ # Configuration files config/diaspora.yml config/initializers/secret_token.rb config/initializers/twofa_encryption_key.rb .bundle vendor/bundle/ vendor/cache/ Loading Changelog.md +3 −0 Original line number Diff line number Diff line Loading @@ -12,6 +12,9 @@ * Enable paranoid mode for devise [#8003](https://github.com/diaspora/diaspora/pull/8003) * Refactor likes cucumber test [#8002](https://github.com/diaspora/diaspora/pull/8002) ## Bug fixes * Fix old photos without remote url for export [#8012](https://github.com/diaspora/diaspora/pull/8012) ## Features * Add a manifest.json file as a first step to make diaspora\* a Progressive Web App [#7998](https://github.com/diaspora/diaspora/pull/7998) * Allow `web+diaspora://` links to link to a profile with only the diaspora ID [#8000](https://github.com/diaspora/diaspora/pull/8000) Loading app/models/user.rb +1 −2 Original line number Diff line number Diff line Loading @@ -19,11 +19,10 @@ class User < ApplicationRecord scope :halfyear_actives, ->(time = Time.now) { logged_in_since(time - 6.month) } scope :active, -> { joins(:person).where(people: {closed_account: false}) } attribute :otp_secret attr_encrypted :otp_secret, if: false, prefix: "plain_" devise :two_factor_authenticatable, :two_factor_backupable, otp_secret_encryption_key: AppConfig.twofa_encryption_key, otp_backup_code_length: 16, otp_number_of_backup_codes: 10 Loading db/migrate/20171229175654_add_devise_two_factor_to_users.rb +7 −5 Original line number Diff line number Diff line Loading @@ -2,10 +2,12 @@ class AddDeviseTwoFactorToUsers < ActiveRecord::Migration[5.1] def change add_column :users, :encrypted_otp_secret, :string add_column :users, :encrypted_otp_secret_iv, :string add_column :users, :encrypted_otp_secret_salt, :string add_column :users, :consumed_timestep, :integer add_column :users, :otp_required_for_login, :boolean change_table :users, bulk: true do |t| t.string :encrypted_otp_secret t.string :encrypted_otp_secret_iv t.string :encrypted_otp_secret_salt t.integer :consumed_timestep t.boolean :otp_required_for_login end end end db/migrate/20190509125709_fix_missing_remote_photo_fields.rb 0 → 100644 +11 −0 Original line number Diff line number Diff line # frozen_string_literal: true class FixMissingRemotePhotoFields < ActiveRecord::Migration[5.1] def up Photo.where(remote_photo_path: nil).each do |photo| photo.write_attribute(:unprocessed_image, photo.read_attribute(:processed_image)) photo.update_remote_path photo.save! end end end Loading
.gitignore +0 −1 Original line number Diff line number Diff line Loading @@ -11,7 +11,6 @@ app/assets/images/custom/ # Configuration files config/diaspora.yml config/initializers/secret_token.rb config/initializers/twofa_encryption_key.rb .bundle vendor/bundle/ vendor/cache/ Loading
Changelog.md +3 −0 Original line number Diff line number Diff line Loading @@ -12,6 +12,9 @@ * Enable paranoid mode for devise [#8003](https://github.com/diaspora/diaspora/pull/8003) * Refactor likes cucumber test [#8002](https://github.com/diaspora/diaspora/pull/8002) ## Bug fixes * Fix old photos without remote url for export [#8012](https://github.com/diaspora/diaspora/pull/8012) ## Features * Add a manifest.json file as a first step to make diaspora\* a Progressive Web App [#7998](https://github.com/diaspora/diaspora/pull/7998) * Allow `web+diaspora://` links to link to a profile with only the diaspora ID [#8000](https://github.com/diaspora/diaspora/pull/8000) Loading
app/models/user.rb +1 −2 Original line number Diff line number Diff line Loading @@ -19,11 +19,10 @@ class User < ApplicationRecord scope :halfyear_actives, ->(time = Time.now) { logged_in_since(time - 6.month) } scope :active, -> { joins(:person).where(people: {closed_account: false}) } attribute :otp_secret attr_encrypted :otp_secret, if: false, prefix: "plain_" devise :two_factor_authenticatable, :two_factor_backupable, otp_secret_encryption_key: AppConfig.twofa_encryption_key, otp_backup_code_length: 16, otp_number_of_backup_codes: 10 Loading
db/migrate/20171229175654_add_devise_two_factor_to_users.rb +7 −5 Original line number Diff line number Diff line Loading @@ -2,10 +2,12 @@ class AddDeviseTwoFactorToUsers < ActiveRecord::Migration[5.1] def change add_column :users, :encrypted_otp_secret, :string add_column :users, :encrypted_otp_secret_iv, :string add_column :users, :encrypted_otp_secret_salt, :string add_column :users, :consumed_timestep, :integer add_column :users, :otp_required_for_login, :boolean change_table :users, bulk: true do |t| t.string :encrypted_otp_secret t.string :encrypted_otp_secret_iv t.string :encrypted_otp_secret_salt t.integer :consumed_timestep t.boolean :otp_required_for_login end end end
db/migrate/20190509125709_fix_missing_remote_photo_fields.rb 0 → 100644 +11 −0 Original line number Diff line number Diff line # frozen_string_literal: true class FixMissingRemotePhotoFields < ActiveRecord::Migration[5.1] def up Photo.where(remote_photo_path: nil).each do |photo| photo.write_attribute(:unprocessed_image, photo.read_attribute(:processed_image)) photo.update_remote_path photo.save! end end end