Skip to content

Commit

Permalink
[Security Solution] Remove Host Isolation feature flag (#101655)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinlog authored Jun 8, 2021
1 parent 3c68a0c commit 8699803
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export type ExperimentalFeatures = typeof allowedExperimentalValues;
const allowedExperimentalValues = Object.freeze({
trustedAppsByPolicyEnabled: false,
metricsEntitiesEnabled: false,
hostIsolationEnabled: false,
ruleRegistryEnabled: false,
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ export const mockGlobalState: State = {
enableExperimental: {
trustedAppsByPolicyEnabled: false,
metricsEntitiesEnabled: false,
hostIsolationEnabled: false,
ruleRegistryEnabled: false,
},
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ import {
UNISOLATE_HOST,
} from '../../../../detections/components/host_isolation/translations';
import { ALERT_DETAILS } from './translations';
import { useIsExperimentalFeatureEnabled } from '../../../../common/hooks/use_experimental_features';
import { useIsolationPrivileges } from '../../../../common/hooks/endpoint/use_isolate_privileges';

const StyledEuiFlyoutBody = styled(EuiFlyoutBody)`
Expand Down Expand Up @@ -74,8 +73,6 @@ const EventDetailsPanelComponent: React.FC<EventDetailsPanelProps> = ({
skip: !expandedEvent.eventId,
});

const isHostIsolationEnabled = useIsExperimentalFeatureEnabled('hostIsolationEnabled');

const [isHostIsolationPanelOpen, setIsHostIsolationPanel] = useState(false);

const [isolateAction, setIsolateAction] = useState('isolateHost');
Expand Down Expand Up @@ -156,20 +153,17 @@ const EventDetailsPanelComponent: React.FC<EventDetailsPanelProps> = ({
/>
)}
</StyledEuiFlyoutBody>
{isIsolationAllowed &&
isHostIsolationEnabled &&
isEndpointAlert &&
isHostIsolationPanelOpen === false && (
<EuiFlyoutFooter>
<EuiFlexGroup justifyContent="flexEnd">
<EuiFlexItem grow={false}>
<TakeActionDropdown onChange={showHostIsolationPanel} agentId={agentId} />
</EuiFlexItem>
</EuiFlexGroup>
<EuiSpacer size="l" />
<EuiSpacer size="l" />
</EuiFlyoutFooter>
)}
{isIsolationAllowed && isEndpointAlert && isHostIsolationPanelOpen === false && (
<EuiFlyoutFooter>
<EuiFlexGroup justifyContent="flexEnd">
<EuiFlexItem grow={false}>
<TakeActionDropdown onChange={showHostIsolationPanel} agentId={agentId} />
</EuiFlexItem>
</EuiFlexGroup>
<EuiSpacer size="l" />
<EuiSpacer size="l" />
</EuiFlyoutFooter>
)}
</>
) : (
<>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ const mockDeps = {
experimentalFeatures: {
trustedAppsByPolicyEnabled: false,
metricsEntitiesEnabled: false,
hostIsolationEnabled: false,
ruleRegistryEnabled: false,
},
service: {} as EndpointAppContextService,
Expand Down

0 comments on commit 8699803

Please sign in to comment.