src/vs/workbench/contrib/extensions/browser/extensionsWorkbenchService.ts/ExtensionsWorkbenchService/canInstall
class ExtensionsWorkbenchService:	canInstall(extension: IExtension): boolean {
		if (!(extension instanceof Extension)) {
			return false;
		}

		if (extension.isMalicious) {
			return false;
		}

		if (!extension.gallery) {
			return false;
		}

		if (this.extensionManagementServerService.localExtensionManagementServer
			|| this.extensionManagementServerService.remoteExtensionManagementServer) {
			return true;
		}

		if (this.extensionManagementServerService.webExtensionManagementServer) {
			return extension.gallery.webExtension;
		}

		return false;
	}