-
Notifications
You must be signed in to change notification settings - Fork 557
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
New profiles: jami and postman #5691
Conversation
etc/profile-m-z/postman.profile
Outdated
mkdir ${HOME}/.config/Postman | ||
whitelist ${HOME}/.config/Postman | ||
|
||
#private-opt postman |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you've checked that the app is never installed to /opt, you can drop this line. If not, add it uncommented below private-etc for alphabetical ordering.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is installed, but I couldn't make it work with private-opt.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is installed, but I couldn't make it work with private-opt.
I'm not familiar with this postman app so I can't be sure why you couldn't get it to work with private-opt. But when I look at postman.desktop that suggests there are 2 executables involved. The one in /usr/bin/postman is symlinked to the second, /opt/postman/Postman. Yet there's only postman
in private-bin. Have you tried getting private-opt working by also adding Postman
to private-bin? This case-sensitivity might just do it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for these profiles! Some minor placement remarks.
Sorry for the late feedback. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Try private-opt again when adding Postman
to private-bin (that's a capital P).
|
|
I've installed that AUR package and got a working profile. This a quite a large app, causing private-opt to hit firejail's file-copy-limit of 500MB. You can find that setting in /etc/firejail/firejail.config. I recommend against raising it, although it's possible. We had a similar thing with microsoft-edge in #5307 and opted to whitelist /opt/foo instead, which is nicer than draining RAM IMO. Anyway, here's my working postman.profile: $ cat /etc/firejail/postman.profile
As you can see it needed a few extra options, like allowing nodejs. I forgot we had a refactor of electron recently, the redirect should now go to electron-common.profile. You can test it further, I'm not familiar with postman but the basics seem to work fine now. |
I don't think I'm gonna be using Postman for a while. I wanted to contribute old working profiles. |
Understood. Firejail is an evolving project and it does take time to keep profiles in working order. No problem though, you're in control of the PR :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix private-bin sorting and we can bring this in.
@Kobaxidze256 Please rebase to the upstream master to fix the conflicts and Example (assuming that git remote -v # check the remotes
git fetch origin
git rebase -i origin/master |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since there is also a capitalized Postman
executable, add a redirect profile
for it:
etc/profile-m-z/Postman.profile:
# Firejail profile for Postman
# This file is overwritten after every install/update
# Persistent local customizations
include Postman.local
# Persistent global definitions
# added by included profile
#include globals.local
# Redirect
include postman.profile
Edit: Also, add Postman
to firecfg.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move Postman entree to respect case-sensitive ordering.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
No problem.
The C/POSIX collation just uses the raw character values for sorting AFAIK. And in ASCII all uppercase letters have a lower value than the lowercase letters: $ ascii
|00 nul|01 soh|02 stx|03 etx|04 eot|05 enq|06 ack|07 bel|
|08 bs |09 ht |0a nl |0b vt |0c np |0d cr |0e so |0f si |
|10 dle|11 dc1|12 dc2|13 dc3|14 dc4|15 nak|16 syn|17 etb|
|18 can|19 em |1a sub|1b esc|1c fs |1d gs |1e rs |1f us |
|20 sp |21 ! |22 " |23 # |24 $ |25 % |26 & |27 ' |
|28 ( |29 ) |2a * |2b + |2c , |2d - |2e . |2f / |
|30 0 |31 1 |32 2 |33 3 |34 4 |35 5 |36 6 |37 7 |
|38 8 |39 9 |3a : |3b ; |3c < |3d = |3e > |3f ? |
|40 @ |41 A |42 B |43 C |44 D |45 E |46 F |47 G |
|48 H |49 I |4a J |4b K |4c L |4d M |4e N |4f O |
|50 P |51 Q |52 R |53 S |54 T |55 U |56 V |57 W |
|58 X |59 Y |5a Z |5b [ |5c \ |5d ] |5e ^ |5f _ |
|60 ` |61 a |62 b |63 c |64 d |65 e |66 f |67 g |
|68 h |69 i |6a j |6b k |6c l |6d m |6e n |6f o |
|70 p |71 q |72 r |73 s |74 t |75 u |76 v |77 w |
|78 x |79 y |7a z |7b { |7c | |7d } |7e ~ |7f del| So when sorting, the uppercase letters always come earlier, not just on the Examples: $ printf 'aaa\nBBB\nccc\n' | LC_ALL=C sort
BBB
aaa
ccc
$ printf 'Aaa\nAAa\n' | LC_ALL=C sort
AAa
Aaa
$ printf 'Aaa\nABa\n' | LC_ALL=C sort
ABa
Aaa vim also does this when using the Do you have a similar command in your editor? If so, what is the result of sorting like in the examples? |
@kmk3 Excellent explanation, thanks. I've added a shortcut to my GUI editor (geany) and will check it in nano too now I have the rundown. Sorting is working exactly like in your examples. One less thing :) |
No description provided.