@@ -4,10 +4,6 @@ Feature: encryption command
4
4
I want to encrypt-decrypt my data
5
5
So that users' resources are protected
6
6
7
- # Background:
8
- # Given the administrator has invoked occ command "encryption:enable"
9
- # And the administrator has selected master key encryption type using the occ command
10
-
11
7
12
8
Scenario : view current encryption status
13
9
When the administrator invokes occ command "encryption:status"
@@ -28,6 +24,18 @@ Feature: encryption command
28
24
And the command output should contain the text "Current key storage root: default storage location (data/)"
29
25
30
26
27
+ Scenario : it should be possible to disable encryption after decrypting all of the encrypted files
28
+ Given the administrator has uploaded file with content "uploaded content" to "/lorem.txt"
29
+ And the administrator has decrypted everything
30
+ When the administrator disables encryption using the occ command
31
+ Then the command should have been successful
32
+ And the command output should contain the text "Cleaned up config"
33
+ And the command output should contain the text "Encryption disabled"
34
+ When the administrator invokes occ command "encryption:status"
35
+ Then the command should have been successful
36
+ And the command output should contain the text "enabled: false"
37
+
38
+
31
39
Scenario : data file contents should be encrypted
32
40
Given user "Alice" has been created with default attributes and without skeleton files
33
41
When user "Alice" uploads file with content "file to upload" to "/fileToUpload.txt" using the WebDAV API
@@ -42,23 +50,11 @@ Feature: encryption command
42
50
43
51
Scenario : it should not be possible to disable encryption without decrypting encrypted uploaded files
44
52
Given the administrator has uploaded file with content "uploaded content" to "/lorem.txt"
45
- When the administrator invokes occ command "encryption:disable"
53
+ When the administrator disables encryption using the occ command
46
54
Then the command should have failed with exit code 1
47
55
And the command output should contain the text "The system still have encrypted files. Please decrypt them all before disabling encryption."
48
56
49
57
50
- Scenario : it should be possible to disable encryption after decrypting all of the encrypted files
51
- Given the administrator has uploaded file with content "uploaded content" to "/lorem.txt"
52
- And the administrator has decrypted everything
53
- And the administrator invokes occ command "encryption:disable"
54
- Then the command should have been successful
55
- And the command output should contain the text "Cleaned up config"
56
- And the command output should contain the text "Encryption disabled"
57
- When the administrator invokes occ command "encryption:status"
58
- Then the command should have been successful
59
- And the command output should contain the text "enabled: false"
60
-
61
-
62
58
Scenario : move encryption keys to a different folder
63
59
When the administrator invokes occ command "encryption:change-key-storage-root owncloud-keys"
64
60
Then the command should have been successful
@@ -70,6 +66,6 @@ Feature: encryption command
70
66
@skipOnOcV10 @issue-encryption-303
71
67
Scenario : it should not be possible to disable encryption even after decrypting all encrypted files if keys root has been changed
72
68
Given the administrator has decrypted everything
73
- When the administrator invokes occ command "encryption:disable"
69
+ When the administrator disables encryption using the occ command
74
70
Then the command should have failed with exit code 1
75
71
And the command output should contain the text "The system still have encrypted files. Please decrypt them all before disabling encryption"
0 commit comments