Main password encrypted in memory
This commit is contained in:
@@ -22,7 +22,10 @@ func exists(filename string) bool {
|
||||
func createId(t *testing.T) *Identity {
|
||||
config := GetConfig()
|
||||
config.IdentityFile = "test.id"
|
||||
config.memoryPassword = "generalPassword"
|
||||
err := config.SetMemPass("generalPassword")
|
||||
if err != nil {
|
||||
t.Fatalf("Failed to set password: %v", err)
|
||||
}
|
||||
// ! Extension to quickly open db : Debug only !
|
||||
config.DbSuffix = ".sqlite"
|
||||
id, err := CreateIdentity("myname")
|
||||
@@ -123,7 +126,10 @@ func TestGetRequestJobs(t *testing.T) {
|
||||
id.MessageServers = ServerStorage{
|
||||
DbFile: "test.db",
|
||||
}
|
||||
GetConfig().SetMemPass("test")
|
||||
err := GetConfig().SetMemPass("test")
|
||||
if err != nil {
|
||||
t.Fatalf("Failed to set password: %v", err)
|
||||
}
|
||||
GetConfig().SetIdentity(id)
|
||||
for i := 1; i < 10; i++ {
|
||||
// initialize a Server with name "server+i"
|
||||
|
||||
Reference in New Issue
Block a user