Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add the /secret command for encrypted-message #382

Merged
merged 3 commits into from
Jan 26, 2024

Conversation

maxneuvians
Copy link
Contributor

This PR adds the /secret command to generate one time encrypted message links

  1. Use command
    Screenshot 2024-01-26 at 10 56 55 AM

  2. Select options
    Screenshot 2024-01-26 at 10 57 36 AM

  3. Get link to share:
    Screenshot 2024-01-26 at 10 57 49 AM

Copy link

github-actions bot commented Jan 26, 2024

GitHub Action status on 5438cf0 generated by comment-failure-action

Source code security scan using Bandit

job url
null https://github.com/cds-snc/sre-bot/actions/runs/7670369576/job/20906387542

Lint, format and test code

job url
null https://github.com/cds-snc/sre-bot/actions/runs/7670369580/job/20906387447

Build containers CI

No jobs failed 👍

Copy link

github-actions bot commented Jan 26, 2024

GitHub Action status on ffc67d7 generated by comment-failure-action

Source code security scan using Bandit

job url
null https://github.com/cds-snc/sre-bot/actions/runs/7670650853/job/20907306331

Lint, format and test code

No jobs failed 👍

Build containers CI

No jobs failed 👍

Copy link
Contributor

@sylviamclaughlin sylviamclaughlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work Max and super handy!

ttl = view["state"]["values"]["product"]["secret_ttl"]["selected_option"]["value"]

# Encrypted message API
endpoint = "https://encrypted-message.cdssandbox.xyz/encrypt"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super, super minor thing which we don't need to change, but the URL https://encrypted-message.cdssandbox.xyz might be better to live in a variable or secret since you are anyways using it in multiple places throughout your code. Again super minor.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed - I hardcoded it for now but should be made into an env in the future

@maxneuvians maxneuvians merged commit 3216631 into main Jan 26, 2024
4 checks passed
@maxneuvians maxneuvians deleted the feat/secret_command branch January 26, 2024 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants