%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/samba/gp/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/samba/gp/__pycache__/gp_chromium_ext.cpython-312.pyc

�

�I�d:Q���ddlZddlZddlmZmZddlmZddlmZddl	m
Z
ddlmZd�Z
d�Zd	�ZGd
�dee�ZGd�d
e�Zy)�N)�
gp_pol_ext�gp_file_applier)�misc)�
get_string)�log)�NamedTemporaryFilec���gd�}gd�}||vr(tjt|j��S|jt
jk(r||vr|jdk(S|jS)N)(�VirtualKeyboardFeatures�DeviceArcDataSnapshotHours�"RequiredClientCertificateForDevice� RequiredClientCertificateForUser�RegisteredProtocolHandlers�WebUsbAllowDevicesForUrls� DeviceAutoUpdateTimeRestrictions�DeviceUpdateStagingSchedule�DeviceMinimumVersion�DeviceDisplayResolution�ExtensionSettings�KerberosAccounts�$NetworkFileSharesPreconfiguredShares�NetworkThrottlingEnabled�TPMFirmwareUpdateSettings�DeviceOffHours�ParentAccessCodeConfig�PerAppTimeLimits�PerAppTimeLimitsWhitelist�PerAppTimeLimitsAllowlist�UsageTimeLimit�
PluginVmImage� DeviceLoginScreenPowerManagement�PowerManagementIdleSettings�ScreenLockDelays�ScreenBrightnessPercent�DevicePowerPeakShiftDayConfig�(DeviceAdvancedBatteryChargeModeDayConfig�PrintingPaperSizeDefault�AutoLaunchProtocolsFromOrigins�BrowsingDataLifetime�DataLeakPreventionRulesList�*DeviceLoginScreenWebUsbAllowDevicesForUrls�DeviceScheduledUpdateCheck�KeyPermissions�ManagedBookmarks�ManagedConfigurationPerOrigin�
ProxySettings�SystemProxySettings�WebAppInstallForceList(�(ShowAccessibilityOptionsInSystemTrayMenu�LargeCursorEnabled�SpokenFeedbackEnabled�HighContrastEnabled�VirtualKeyboardEnabled�StickyKeysEnabled�KeyboardDefaultToFunctionKeys�DictationEnabled�SelectToSpeakEnabled�KeyboardFocusHighlightEnabled�CursorHighlightEnabled�CaretHighlightEnabled�MonoAudioEnabled�AccessibilityShortcutsEnabled�AutoclickEnabled�*DeviceLoginScreenDefaultLargeCursorEnabled�-DeviceLoginScreenDefaultSpokenFeedbackEnabled�+DeviceLoginScreenDefaultHighContrastEnabled�.DeviceLoginScreenDefaultVirtualKeyboardEnabled�#DeviceLoginScreenLargeCursorEnabled�&DeviceLoginScreenSpokenFeedbackEnabled�$DeviceLoginScreenHighContrastEnabled�'DeviceLoginScreenVirtualKeyboardEnabled�!DeviceLoginScreenDictationEnabled�%DeviceLoginScreenSelectToSpeakEnabled�'DeviceLoginScreenCursorHighlightEnabled�&DeviceLoginScreenCaretHighlightEnabled�!DeviceLoginScreenMonoAudioEnabled�!DeviceLoginScreenAutoclickEnabled�"DeviceLoginScreenStickyKeysEnabled�.DeviceLoginScreenKeyboardFocusHighlightEnabled�,DeviceLoginScreenShowOptionsInSystemTrayMenu�.DeviceLoginScreenAccessibilityShortcutsEnabled� FloatingAccessibilityMenuEnabled�
ArcEnabled�UnaffiliatedArcAllowed�!AppRecommendationZeroStateEnabled�DeviceBorealisAllowed�UserBorealisAllowed�SystemUse24HourClock�DefaultSearchProviderEnabled�ChromeOsReleaseChannelDelegated�DeviceAutoUpdateDisabled�DeviceAutoUpdateP2PEnabled� DeviceUpdateHttpDownloadsEnabled�RebootAfterUpdate�BlockExternalExtensions�VoiceInteractionContextEnabled�VoiceInteractionHotwordEnabled�EnableMediaRouter�ShowCastIconInToolbar�
DriveDisabled�DriveDisabledOverCellular�DisableAuthNegotiateCnameLookup�EnableAuthNegotiatePort�BasicAuthOverHttpEnabled� AuthNegotiateDelegateByKdcPolicy�AllowCrossOriginAuthPrompt�
NtlmV2Enabled�"IntegratedWebAuthenticationAllowed�BrowserSwitcherEnabled� BrowserSwitcherKeepLastChromeTab�BrowserSwitcherUseIeSitelist�VirtualMachinesAllowed�CrostiniAllowed�!DeviceUnaffiliatedCrostiniAllowed�CrostiniExportImportUIAllowed�CrostiniPortForwardingAllowed�NativeMessagingUserLevelHosts�NetworkFileSharesAllowed�NetBiosShareDiscoveryEnabled�NTLMShareAuthenticationEnabled�DeviceDataRoamingEnabled�DeviceWiFiFastTransitionEnabled�DeviceWiFiAllowed�DeviceAllowBluetooth�+DeviceAllowRedeemChromeOsRegistrationOffers�DeviceQuirksDownloadEnabled�SuggestedContentEnabled�"DeviceShowLowDiskSpaceNotification�PasswordManagerEnabled�PasswordLeakDetectionEnabled�PluginVmAllowed�PluginVmDataCollectionAllowed�UserPluginVmAllowed�DeviceRebootOnShutdown� PowerManagementUsesAudioActivity� PowerManagementUsesVideoActivity�AllowWakeLocks�AllowScreenWakeLocks�WaitForInitialUserActivity�PowerSmartDimEnabled�DevicePowerPeakShiftEnabled�DeviceBootOnAcEnabled�&DeviceAdvancedBatteryChargeModeEnabled�DeviceUsbPowerShareEnabled�PrintingEnabled�CloudPrintProxyEnabled�&PrintingSendUsernameAndFilenameEnabled�CloudPrintSubmitEnabled�DisablePrintPreview�PrintHeaderFooter�#PrintPreviewUseSystemDefaultPrinter�UserNativePrintersAllowed�UserPrintersAllowed�DeletePrintJobHistoryAllowed�%DeviceLoginScreenPrivacyScreenEnabled�PrivacyScreenEnabled�PinUnlockWeakPinsAllowed�PinUnlockAutosubmitEnabled�!RemoteAccessHostFirewallTraversal�RemoteAccessHostRequireCurtain�"RemoteAccessHostAllowClientPairing�&RemoteAccessHostAllowRelayedConnection�0RemoteAccessHostAllowUiAccessForRemoteAssistance�!RemoteAccessHostAllowFileTransfer�,RemoteAccessHostAllowRemoteAccessConnections�AttestationEnabledForUser�SafeBrowsingEnabled�$SafeBrowsingExtendedReportingEnabled�DeviceGuestModeEnabled�DeviceAllowNewUsers�DeviceShowUserNamesOnSignin�DeviceEphemeralUsersEnabled�$DeviceShowNumericKeyboardForPassword�DeviceFamilyLinkAccountsAllowed�ShowHomeButton�HomepageIsNewTabPage�DeviceMetricsReportingEnabled�DeviceWilcoDtcAllowed�$AbusiveExperienceInterventionEnforce�AccessibilityImageLabelsEnabled�AdditionalDnsQueryTypesEnabled�AdvancedProtectionAllowed�AllowDeletingBrowserHistory�AllowDinosaurEasterEgg�AllowFileSelectionDialogs�AllowScreenLock�AllowSyncXHRInPageDismissal�AlternateErrorPagesEnabled�AlwaysOpenPdfExternally�AppCacheForceEnabled�AudioCaptureAllowed�AudioOutputAllowed�AudioProcessHighPriorityEnabled�AudioSandboxEnabled�AutoFillEnabled�AutofillAddressEnabled�AutofillCreditCardEnabled�AutoplayAllowed�BackgroundModeEnabled�BlockThirdPartyCookies�BookmarkBarEnabled�BrowserAddPersonEnabled�BrowserGuestModeEnabled�BrowserGuestModeEnforced�BrowserLabsEnabled� BrowserNetworkTimeQueriesEnabled�BuiltInDnsClientEnabled�
CECPQ2Enabled�'CaptivePortalAuthenticationIgnoresProxy�ChromeCleanupEnabled�ChromeCleanupReportingEnabled�ChromeOsLockOnIdleSuspend�ClickToCallEnabled�"CloudManagementEnrollmentMandatory�"CloudPolicyOverridesPlatformPolicy�CloudUserPolicyMerge�&CommandLineFlagSecurityWarningsEnabled�ComponentUpdatesEnabled�DNSInterceptionChecksEnabled�"DataLeakPreventionReportingEnabled�DefaultBrowserSettingEnabled�-DefaultSearchProviderContextMenuAccessAllowed�DeveloperToolsDisabled�&DeviceAllowMGSToStoreDisplayProperties�DeviceDebugPacketCaptureAllowed�'DeviceLocalAccountManagedSessionEnabled�)DeviceLoginScreenPrimaryMouseButtonSwitch�$DevicePciPeripheralDataAccessEnabled�DevicePowerwashAllowed�DeviceSystemWideTracingEnabled�
Disable3DAPIs� DisableSafeBrowsingProceedAnyway�DisableScreenshots�EasyUnlockAllowed�EditBookmarksEnabled�EmojiSuggestionEnabled�EnableDeprecatedPrivetPrinting�EnableOnlineRevocationChecks�EnableSyncConsent�$EnterpriseHardwarePlatformAPIEnabled�,ExternalProtocolDialogShowAlwaysOpenCheckbox�ExternalStorageDisabled�ExternalStorageReadOnly�ForceBrowserSignin�ForceEphemeralProfiles�ForceGoogleSafeSearch�ForceMaximizeOnFirstRun�ForceSafeSearch�ForceYouTubeSafetyMode�FullscreenAlertEnabled�FullscreenAllowed�!GloballyScopeHTTPAuthCacheEnabled�HardwareAccelerationModeEnabled�HideWebStoreIcon�ImportAutofillFormData�ImportBookmarks�
ImportHistory�ImportHomepage�ImportSavedPasswords�ImportSearchEngine�IncognitoEnabled�InsecureFormsWarningsEnabled�%InsecurePrivateNetworkRequestsAllowed�InstantTetheringAllowed� IntensiveWakeUpThrottlingEnabled�JavascriptEnabled�
LacrosAllowed�LacrosSecondaryProfilesAllowed�LockScreenMediaPlaybackEnabled�!LoginDisplayPasswordButtonEnabled�)ManagedGuestSessionPrivacyWarningsEnabled�MediaRecommendationsEnabled�MediaRouterCastAllowAllIPs�MetricsReportingEnabled�NTPCardsVisible�NTPCustomBackgroundEnabled�NativeWindowOcclusionEnabled�NearbyShareAllowed�PaymentMethodQueryEnabled�PdfAnnotationsEnabled�PhoneHubAllowed�PhoneHubNotificationsAllowed�PhoneHubTaskContinuationAllowed�PolicyAtomicGroupsEnabled�PrimaryMouseButtonSwitch�PromotionalTabsEnabled�PromptForDownloadLocation�QuicAllowed�RendererCodeIntegrityEnabled�,RequireOnlineRevocationChecksForLocalAnchors�RoamingProfileSupportEnabled�SSLErrorOverrideAllowed�$SafeBrowsingForTrustedSourcesEnabled�SavingBrowserHistoryDisabled�ScreenCaptureAllowed�ScrollToTextFragmentEnabled�SearchSuggestEnabled�#SecondaryGoogleAccountSigninAllowed�*SharedArrayBufferUnrestrictedAccessAllowed�SharedClipboardEnabled�ShowAppsShortcutInBookmarkBar�ShowFullUrlsInAddressBar�ShowLogoutButtonInTray�SignedHTTPExchangeEnabled�
SigninAllowed�SigninInterceptionEnabled�SitePerProcess�SmartLockSigninAllowed�SmsMessagesAllowed�SpellCheckServiceEnabled�SpellcheckEnabled�$StartupBrowserWindowLaunchSuppressed�$StricterMixedContentTreatmentEnabled�#SuggestLogoutAfterClosingLastWindow�&SuppressDifferentOriginSubframeDialogs�SuppressUnsupportedOSWarning�SyncDisabled�TargetBlankImpliesNoOpener�TaskManagerEndProcessEnabled�ThirdPartyBlockingEnabled�TouchVirtualKeyboardEnabled�TranslateEnabled�TripleDESEnabled�UnifiedDesktopEnabledByDefault�'UrlKeyedAnonymizedDataCollectionEnabled�UserAgentClientHintsEnabled�UserFeedbackAllowed�VideoCaptureAllowed�VmManagementCliAllowed�VpnConfigAllowed�WPADQuickCheckEnabled�WebRtcAllowLegacyTLSProtocols�WebRtcEventLogCollectionAllowed�WifiSyncAndroidAllowed�WindowOcclusionEnabled�)�json�loadsr�data�typer�	REG_DWORD)�name�e�dict_entries�boolss    �:/usr/lib/python3/dist-packages/samba/gp/gp_chromium_ext.py�parse_entry_datar\sb��'.�L�P^
'�E�~�|���z�z�*�Q�V�V�,�-�-�	
���4�>�>�	!�d�e�m��v�v��{���6�6�M�c��|jj�rF|jjd�d}||vrg||<||j	t||��y|j}t||�||<y)N�\���)�	valuename�	isnumeric�keyname�split�appendr\)�policiesrXrWs   r[�assign_entryrggsm���{�{�����y�y���t�$�R�(���x���H�T�N������.�t�Q�7�8��{�{��)�$��2���r]c��i}i}dj|dg�}|D]a}d|jvr�|jj|�r
t	||��:|jj|�s�Vt	||��c||fS)Nr_�Recommendedz
**delvals.)�joinrarc�
startswithrg)�section�entries�managed�recommended�recommended_sectionrXs      r[�convert_pol_to_jsonrqqs����G��K��)�)�W�m�$<�=��
�%���1�;�;�&���9�9��� 3�4���a�(�
�Y�Y�
!�
!�'�
*���!�$�
%��K��r]c�*�eZdZdZdZd�Z	dd�Zd�Zy)�gp_chromium_extz/etc/chromium/policies/managedz"/etc/chromium/policies/recommendedc��y)NzGoogle/Chromium���selfs r[�__str__zgp_chromium_ext.__str__�s�� r]Nc	���|�Jtjj|d�|_tjj|d�|_tjj|j�s"tj|jdd��tjj|j�s"tj|jdd��|D]�\}}t|�|vs�|t|�j�D]�\}}	tj|�|dk(r+tjj|jd�}n/|dk(r*tjj|jd�}|j||�����|D�]
}	|	js�d}
d}tjj|	j|�}|j|�}
|
s�St!|
|
j"�\}}d	�}|j%tj&|��}|j)|	j*d||||j�|j%tj&|��}|j)|	j*d||||j���
y#tjj$r|j|||�Y���wxYw)
Nrorni�T)�mode�exist_okz
policies.json�Software\Policies\Google\Chrome�MACHINE/Registry.polc�L�	tddd|d��5}tj||�tj|j
d�t
jd|�|j
gcddd�S#1swYyxYw#t$rt
jd|�YywxYw)	Nzw+�gp_Fz.json)rz�prefix�delete�dir�suffixi�zWrote Chromium preferencesz$Failed to write Chromium preferences)	rrR�dump�os�chmodrWr�debug�PermissionError)rf�location�fs   r[�applier_funcz:gp_chromium_ext.process_group_policy.<locals>.applier_func�s���,�/�T�%�7<�4<�7>�@�,�DE� �I�I�h��2��H�H�Q�V�V�U�3��I�I�&B�H�M�$%�F�F�8�,�,�,��+�,��	�	�"H�"*�,�,�s/�B�AA5�+	B�5A>�:B�>B�B#�"B#)r��pathrj�recommended_policies_path�managed_policies_path�exists�makedirs�str�itemsrRrS�unapply�decoder�JSONDecodeError�
file_sys_path�parserqrm�generate_value_hash�dumps�applyrW)rw�deleted_gpo_list�changed_gpo_list�
policy_dir�guid�settings�	attributerf�fname�gporl�pol_filer��pol_confrnror��
value_hashs                  r[�process_group_policyz$gp_chromium_ext.process_group_policy�si���!�-/�W�W�\�\�*�<I�.K�D�*�)+�����j�)�)L�D�&��w�w�~�~�d�<�<�=��K�K��6�6�U�!%�
'��w�w�~�~�d�8�8�9��K�K��2�2��!%�
'�.�	=�N�D�(��4�y�H�$�+3�C��I�+>�+D�+D�+F�=�'�I�x�=��
�
�8�,�%�
�5�$&�G�G�L�L��1O�1O�1@�%B�E�&�)�3�$&�G�G�L�L��1K�1K�1@�%B�E����T�9�e�<�#=�	=�*$�	H�C�� � �>��1���w�w�|�|�C�$5�$5�x�@���:�:�d�+����':�7�;C�;K�;K�(M�$���,�"�5�5�d�j�j��6I�J�
��
�
�3�8�8�Y�
�L�"�D�$>�$>�@�!�5�5�d�j�j��6M�N�
��
�
�3�8�8�]�J��&��(F�(F�H�9	H��! �<�<�7�7�@����T�9�h�?�@�s�J8�80K,�+K,c�R�i}d}d}|jr�tjj|j|�}|j	|�}|s|S|j
D]F}|jj|�s�|j||j�d|j��<�H|S)Nr}r|r_)
r�r�r�rjr�rmrcrkrTra)rwr��outputr�rlr�r�rXs        r[�rsopzgp_chromium_ext.rsop�s�����)��6������7�7�<�<�� 1� 1�8�<�D��z�z�$�'�H���
��%�%�
I���9�9�'�'��0�BC�&�&�F�q�y�y�!�+�+�>�?�
I��
r])N)�__name__�
__module__�__qualname__r�r�rxr�r�rur]r[rsrs~s$��<�� D��!�)-�?H�Br]rsc��eZdZdZdZd�Zy)�
gp_chrome_extz /etc/opt/chrome/policies/managedz$/etc/opt/chrome/policies/recommendedc��y)Nz
Google/Chromerurvs r[rxzgp_chrome_ext.__str__�s��r]N)r�r�r�r�r�rxrur]r[r�r��s��>�� F��r]r�)r�rR�samba.gp.gpclassrr�samba.dcerpcr�samba.commonr�samba.gp.util.loggingr�tempfilerr\rgrqrsr�rur]r[�<module>r�sJ��"
��8��#�%�'�L�\
3� �T�j�/�T�l�O�r]

Zerion Mini Shell 1.0