Merge branch 'master' of github.com:diaspora/diaspora_rails
This commit is contained in:
commit
d21a3baf32
8 changed files with 9 additions and 7 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -1,8 +1,10 @@
|
|||
.idea
|
||||
*.swp
|
||||
*.swo
|
||||
*~
|
||||
.bundle
|
||||
db/*.sqlite3
|
||||
log/*.log
|
||||
tmp/**/*
|
||||
gpg/diaspora*/*
|
||||
gpg/diaspora-development/*.gpg
|
||||
gpg/diaspora-production/*.gpg
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ class User < Person
|
|||
:recoverable, :rememberable, :trackable, :validatable
|
||||
|
||||
|
||||
#before_create :assign_key
|
||||
before_create :assign_key
|
||||
validates_presence_of :profile
|
||||
|
||||
before_validation :do_bad_things
|
||||
|
|
@ -68,7 +68,7 @@ class User < Person
|
|||
def assign_key
|
||||
keys = GPGME.list_keys(nil, true)
|
||||
if keys.empty?
|
||||
generate_key
|
||||
#generate_key
|
||||
end
|
||||
self.key_fingerprint = GPGME.list_keys(nil, true).first.subkeys.first.fingerprint
|
||||
end
|
||||
|
|
|
|||
|
|
@ -10,5 +10,5 @@ end
|
|||
|
||||
package :tools do
|
||||
description 'Useful tools'
|
||||
apt 'psmisc htop elinks'
|
||||
apt 'psmisc htop elinks screen'
|
||||
end
|
||||
|
|
|
|||
BIN
gpg/diaspora-test/pubring.gpg
Normal file
BIN
gpg/diaspora-test/pubring.gpg
Normal file
Binary file not shown.
BIN
gpg/diaspora-test/random_seed
Normal file
BIN
gpg/diaspora-test/random_seed
Normal file
Binary file not shown.
BIN
gpg/diaspora-test/secring.gpg
Normal file
BIN
gpg/diaspora-test/secring.gpg
Normal file
Binary file not shown.
BIN
gpg/diaspora-test/trustdb.gpg
Normal file
BIN
gpg/diaspora-test/trustdb.gpg
Normal file
Binary file not shown.
|
|
@ -2,9 +2,9 @@ require File.dirname(__FILE__) + '/spec_helper'
|
|||
|
||||
describe 'user encryption' do
|
||||
before :all do
|
||||
ctx = GPGME::Ctx.new
|
||||
keys = ctx.keys
|
||||
keys.each{|k| ctx.delete_key(k, true)}
|
||||
#ctx = GPGME::Ctx.new
|
||||
#keys = ctx.keys
|
||||
#keys.each{|k| ctx.delete_key(k, true)}
|
||||
@u = User.new
|
||||
@u.email = "george@aol.com"
|
||||
@u.password = "bluepin7"
|
||||
|
|
|
|||
Loading…
Reference in a new issue