@@ -33,7 +33,6 @@ import { IStorageService, StorageScope, StorageTarget } from 'vs/platform/storag
33
33
import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace' ;
34
34
import { IContextKeyService , ContextKeyExpr , RawContextKey , IContextKey } from 'vs/platform/contextkey/common/contextkey' ;
35
35
import { IContextMenuService } from 'vs/platform/contextview/browser/contextView' ;
36
- import { getMaliciousExtensionsSet } from 'vs/platform/extensionManagement/common/extensionManagementUtil' ;
37
36
import { ILogService } from 'vs/platform/log/common/log' ;
38
37
import { INotificationService } from 'vs/platform/notification/common/notification' ;
39
38
import { IHostService } from 'vs/workbench/services/host/browser/host' ;
@@ -60,6 +59,7 @@ import { IPaneCompositePartService } from 'vs/workbench/services/panecomposite/b
60
59
import { coalesce } from 'vs/base/common/arrays' ;
61
60
import { extractEditorsAndFilesDropData } from 'vs/platform/dnd/browser/dnd' ;
62
61
import { extname } from 'vs/base/common/resources' ;
62
+ import { areSameExtensions } from 'vs/platform/extensionManagement/common/extensionManagementUtil' ;
63
63
64
64
const SearchMarketplaceExtensionsContext = new RawContextKey < boolean > ( 'searchMarketplaceExtensions' , false ) ;
65
65
const SearchIntalledExtensionsContext = new RawContextKey < boolean > ( 'searchInstalledExtensions' , false ) ;
@@ -807,12 +807,11 @@ export class MaliciousExtensionChecker implements IWorkbenchContribution {
807
807
}
808
808
809
809
private checkForMaliciousExtensions ( ) : Promise < void > {
810
- return this . extensionsManagementService . getExtensionsControlManifest ( ) . then ( report => {
811
- const maliciousSet = getMaliciousExtensionsSet ( report ) ;
810
+ return this . extensionsManagementService . getExtensionsControlManifest ( ) . then ( extensionsControlManifest => {
812
811
813
812
return this . extensionsManagementService . getInstalled ( ExtensionType . User ) . then ( installed => {
814
813
const maliciousExtensions = installed
815
- . filter ( e => maliciousSet . has ( e . identifier . id ) ) ;
814
+ . filter ( e => extensionsControlManifest . malicious . some ( identifier => areSameExtensions ( e . identifier , identifier ) ) ) ;
816
815
817
816
if ( maliciousExtensions . length ) {
818
817
return Promises . settled ( maliciousExtensions . map ( e => this . extensionsManagementService . uninstall ( e ) . then ( ( ) => {
0 commit comments