This repository was archived by the owner on Mar 2, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Post sealed box & Decrypt response #19
Merged
Merged
Changes from all commits
Commits
Show all changes
39 commits
Select commit
Hold shift + click to select a range
8de6e71
more interfaces
jongbonga 8c0acd9
post messageData
jongbonga eee5f6f
post and decrypt box
jongbonga d016d72
secret key getter, sealbox action
jongbonga 6533625
decrypt message
jongbonga 1e6a8f9
moved post encryted box method to vuex
jongbonga 4893d73
save decrypted msg
jongbonga 9e1e2e3
update mutation nomenclature
jongbonga b31b8f0
show msg dialog and reset on close
jongbonga c2674dd
stop loading after box is sealed and posted
jongbonga b8112a5
action nomanclature
jongbonga a66cde3
no return from action
jongbonga 5d5f8bf
use ourSecretKey's state instead of getters
jongbonga ded93bb
// TODO: Error Handling
jongbonga 8853f7a
check if ourSecretKey is null
jongbonga cf0b2ec
catch requestExecutionToken
jongbonga b667b97
refactor(store): making all the action return types explicit
jongbonga 57cebfd
refactor(AccessForm): use notifyErrors around requestExecutionToken
jongbonga 7b160bc
refactor(AccessForm): change create to request
jongbonga 4d143be
throw instead of returning error
jongbonga 587dfe7
chore(AccessForm): remove TODO
PiDelport 941c574
change decryptedMessage to executionToken
jongbonga 63d0de8
refactor(store): use axios validateStatus to check the status code
PiDelport a4817aa
refactor(store,AccessForm): rename setDecryptedMsg → setExecutionToke…
PiDelport f00c6ce
text(AccessForm): tweak execution token message box title
PiDelport 4364cb1
docs(store): add note about execution token format
PiDelport 061bc93
refactor(store): tweak requestExecutionToken, throw on error
PiDelport d2949ae
fix(store): add await for postAccessForm dispatch
PiDelport 31a65a1
lint(cryptography): yarn lint
PiDelport 8127c3f
refactor(cryptography): pull fields back into EncryptedMessage
PiDelport 47d6912
docs(cryptography): add TODO comment for better local key management
PiDelport 777c231
refactor(store): drop unused code: decryptResponse
PiDelport ff3a078
refactor(models): rename data upload types to "sealed" types
PiDelport 952f893
feat(utils): add checkDefined helper
PiDelport 3f63d9d
refactor(store): use checkDefined for null checks
PiDelport 4a8938f
refactor(AccessForm): remove unused store accessors
PiDelport eff97b7
refactor(store): pull out UploadResult type
PiDelport 2c44236
refactor(store): factor out a common sealedPost helper
PiDelport 7c17610
refactor(store): drop unused secret key from store state
PiDelport File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/** | ||
* Check that a value is defined. | ||
* | ||
* @throws Error if `value` is `null` or `undefined` | ||
*/ | ||
export function checkDefined<T>(value: T | null | undefined): T { | ||
if (value === null) { | ||
throw new Error("unexpected null value"); | ||
} else if (value === undefined) { | ||
throw new Error("unexpected undefined value"); | ||
} | ||
return value; | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.