Skip to content

Commit 3ac0b19

Browse files
Merge pull request #208 from root3nl/207-misleading-update-indicator-for-macos-version-info-item-on-macos-154
207 misleading update indicator for macos version info item on macos 154
2 parents 90b94df + 4712cb8 commit 3ac0b19

12 files changed

Lines changed: 153 additions & 137 deletions

File tree

Configuration Profile Samples/Support App Configuration Sample.mobileconfig

Lines changed: 72 additions & 86 deletions
Original file line numberDiff line numberDiff line change
@@ -5,102 +5,88 @@
55
<key>PayloadContent</key>
66
<array>
77
<dict>
8-
<key>PayloadContent</key>
9-
<dict>
10-
<key>nl.root3.support</key>
11-
<dict>
12-
<key>Forced</key>
13-
<array>
14-
<dict>
15-
<key>mcx_preference_settings</key>
16-
<dict>
17-
<key>ExtensionLinkA</key>
18-
<string>defaults write /Library/Preferences/nl.root3.support.plist ExtensionLoadingA -bool true; /usr/local/bin/jamf policy; /usr/local/bin/jamf_last_check-in_time.zsh</string>
19-
<key>ExtensionSymbolA</key>
20-
<string>clock.badge.checkmark.fill</string>
21-
<key>ExtensionTitleA</key>
22-
<string>Last MDM Check-In</string>
23-
<key>ExtensionTypeA</key>
24-
<string>DistributedNotification</string>
25-
<key>FirstRowLinkLeft</key>
26-
<string>com.teamviewer.TeamViewer</string>
27-
<key>FirstRowLinkMiddle</key>
28-
<string>https://support.root3.nl</string>
29-
<key>FirstRowLinkRight</key>
30-
<string>com.jamfsoftware.selfservice.mac</string>
31-
<key>FirstRowSubtitleLeft</key>
32-
<string>Share your screen</string>
33-
<key>FirstRowSubtitleMiddle</key>
34-
<string>Now</string>
35-
<key>FirstRowSubtitleRight</key>
36-
<string>Download Apps</string>
37-
<key>FirstRowSymbolLeft</key>
38-
<string>cursorarrow.and.square.on.square.dashed</string>
39-
<key>FirstRowSymbolMiddle</key>
40-
<string>lifepreserver</string>
41-
<key>FirstRowSymbolRight</key>
42-
<string>cart.badge.plus</string>
43-
<key>FirstRowTitleLeft</key>
44-
<string>Remote Support</string>
45-
<key>FirstRowTitleMiddle</key>
46-
<string>Get Support</string>
47-
<key>FirstRowTitleRight</key>
48-
<string>Self Service</string>
49-
<key>FirstRowTypeLeft</key>
50-
<string>App</string>
51-
<key>FirstRowTypeMiddle</key>
52-
<string>URL</string>
53-
<key>FirstRowTypeRight</key>
54-
<string>App</string>
55-
<key>FooterText</key>
56-
<string>Provided by your **IT department** with ❤️</string>
57-
<key>HideFirstRow</key>
58-
<false/>
59-
<key>HideSecondRow</key>
60-
<true/>
61-
<key>InfoItemFive</key>
62-
<string>Password</string>
63-
<key>InfoItemSix</key>
64-
<string>ExtensionA</string>
65-
<key>Logo</key>
66-
<string>/Library/Application Support/JAMF/swift-64x64_2x.png</string>
67-
<key>NotificationIcon</key>
68-
<string>/Library/Application Support/JAMF/swift-64x64_2x.png</string>
69-
<key>OnAppearAction</key>
70-
<string>/usr/local/bin/jamf_last_check-in_time.zsh</string>
71-
<key>PasswordExpiryLimit</key>
72-
<integer>14</integer>
73-
<key>PasswordLabel</key>
74-
<string>Cloud Password</string>
75-
<key>PasswordType</key>
76-
<string>KerberosSSO</string>
77-
<key>ShowWelcomeScreen</key>
78-
<true/>
79-
<key>StatusBarIconNotifierEnabled</key>
80-
<true/>
81-
<key>StorageLimit</key>
82-
<integer>90</integer>
83-
<key>Title</key>
84-
<string>Hello **Support App** 2.4</string>
85-
<key>UptimeDaysLimit</key>
86-
<integer>21</integer>
87-
</dict>
88-
</dict>
89-
</array>
90-
</dict>
91-
</dict>
8+
<key>ExtensionLinkA</key>
9+
<string>defaults write /Library/Preferences/nl.root3.support.plist ExtensionLoadingA -bool true; /usr/local/bin/jamf policy; /usr/local/bin/jamf_last_check-in_time.zsh</string>
10+
<key>ExtensionSymbolA</key>
11+
<string>clock.badge.checkmark.fill</string>
12+
<key>ExtensionTitleA</key>
13+
<string>Last MDM Check-In</string>
14+
<key>ExtensionTypeA</key>
15+
<string>DistributedNotification</string>
16+
<key>FirstRowLinkLeft</key>
17+
<string>com.teamviewer.TeamViewer</string>
18+
<key>FirstRowLinkMiddle</key>
19+
<string>https://support.root3.nl</string>
20+
<key>FirstRowLinkRight</key>
21+
<string>com.jamfsoftware.selfservice.mac</string>
22+
<key>FirstRowSubtitleLeft</key>
23+
<string>Share your screen</string>
24+
<key>FirstRowSubtitleMiddle</key>
25+
<string>Now</string>
26+
<key>FirstRowSubtitleRight</key>
27+
<string>Download Apps</string>
28+
<key>FirstRowSymbolLeft</key>
29+
<string>cursorarrow.and.square.on.square.dashed</string>
30+
<key>FirstRowSymbolMiddle</key>
31+
<string>lifepreserver</string>
32+
<key>FirstRowSymbolRight</key>
33+
<string>cart.badge.plus</string>
34+
<key>FirstRowTitleLeft</key>
35+
<string>Remote Support</string>
36+
<key>FirstRowTitleMiddle</key>
37+
<string>Get Support</string>
38+
<key>FirstRowTitleRight</key>
39+
<string>Self Service</string>
40+
<key>FirstRowTypeLeft</key>
41+
<string>App</string>
42+
<key>FirstRowTypeMiddle</key>
43+
<string>URL</string>
44+
<key>FirstRowTypeRight</key>
45+
<string>App</string>
46+
<key>FooterText</key>
47+
<string>Provided by your **IT department** with ❤️</string>
48+
<key>HideFirstRow</key>
49+
<false/>
50+
<key>HideSecondRow</key>
51+
<true/>
52+
<key>InfoItemFive</key>
53+
<string>Password</string>
54+
<key>InfoItemSix</key>
55+
<string>ExtensionA</string>
56+
<key>Logo</key>
57+
<string>/Library/Application Support/JAMF/swift-64x64_2x.png</string>
58+
<key>NotificationIcon</key>
59+
<string>/Library/Application Support/JAMF/swift-64x64_2x.png</string>
60+
<key>OnAppearAction</key>
61+
<string>/usr/local/bin/jamf_last_check-in_time.zsh</string>
62+
<key>PasswordExpiryLimit</key>
63+
<integer>14</integer>
64+
<key>PasswordLabel</key>
65+
<string>Cloud Password</string>
66+
<key>PasswordType</key>
67+
<string>KerberosSSO</string>
68+
<key>ShowWelcomeScreen</key>
69+
<true/>
70+
<key>StatusBarIconNotifierEnabled</key>
71+
<true/>
72+
<key>StorageLimit</key>
73+
<integer>90</integer>
74+
<key>Title</key>
75+
<string>Hello **Support App** 2.4</string>
76+
<key>UptimeDaysLimit</key>
77+
<integer>21</integer>
9278
<key>PayloadDescription</key>
9379
<string></string>
9480
<key>PayloadDisplayName</key>
9581
<string>Custom</string>
9682
<key>PayloadEnabled</key>
9783
<true/>
9884
<key>PayloadIdentifier</key>
99-
<string>com.apple.ManagedClient.preferences.E07B484A-FC4A-450B-A0E9-3BC0B737974B</string>
85+
<string>nl.root3.support.E07B484A-FC4A-450B-A0E9-3BC0B737974B</string>
10086
<key>PayloadOrganization</key>
10187
<string>Root3</string>
10288
<key>PayloadType</key>
103-
<string>com.apple.ManagedClient.preferences</string>
89+
<string>nl.root3.support</string>
10490
<key>PayloadUUID</key>
10591
<string>E07B484A-FC4A-450B-A0E9-3BC0B737974B</string>
10692
<key>PayloadVersion</key>

Extension Sample Scripts/sap_privileges_change_permissions.zsh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,25 +24,26 @@
2424
preference_file_location="/Library/Preferences/nl.root3.support.plist"
2525

2626
# SAP Privileges CLI
27-
sap_privileges_cli="/Applications/Privileges.app/Contents/Resources/PrivilegesCLI"
27+
sap_privileges_cli="/Applications/Privileges.app/Contents/macOS/PrivilegesCLI"
2828

2929
# Start spinning indicator
3030
defaults write "${preference_file_location}" ExtensionLoadingB -bool true
3131

3232
# Replace value with placeholder while loading
3333
defaults write "${preference_file_location}" ExtensionValueB -string "KeyPlaceholder"
3434

35-
# Get the username of the currently logged in user
35+
# Get the username and uid of the currently logged in user
3636
username=$(scutil <<< "show State:/Users/ConsoleUser" | awk '/Name :/ && ! /loginwindow/ { print $3 }')
37+
uid=$(id -u "$username")
3738

3839
# Check if user is administrator
3940
is_admin=$(dsmemberutil checkmembership -U "${username}" -G admin)
4041

4142
# Change permissions
4243
if [[ ${is_admin} != *not* ]]; then
43-
sudo -u ${username} ${sap_privileges_cli} --remove
44+
launchctl asuser "$uid" sudo -u ${username} ${sap_privileges_cli} --remove
4445
else
45-
sudo -u ${username} ${sap_privileges_cli} --add
46+
launchctl asuser "$uid" sudo -u ${username} ${sap_privileges_cli} --add
4647
fi
4748

4849
# Run Support App Extension to report new permission status

Jamf Pro Custom Schema/Jamf Pro Custom Schema.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1069,11 +1069,11 @@
10691069
]
10701070
},
10711071
"DisablePrivilegedHelperTool": {
1072-
"title": "Disable Privileged Helper Tool",
1073-
"description": "Option to disable the Privileged Helper Tool. Re-enabling requires the reinstallation of the Support App.",
1072+
"title": "Enable or Disable Privileged Helper Tool",
1073+
"description": "Option to enable or disable the Privileged Helper Tool. Re-enabling requires the reinstallation of the Support App.",
10741074
"type": "boolean",
10751075
"options": {
1076-
"enum_titles": ["Enable", "Disable"],
1076+
"enum_titles": ["Disable", "Enable"],
10771077
"infoText": "Key name: DisablePrivilegedHelperTool"
10781078
},
10791079
"links": [

0 commit comments

Comments
 (0)