Skip to content

Commit

Permalink
ui: Add External Infos for Hostnames
Browse files Browse the repository at this point in the history
  • Loading branch information
Aurélie Ambal authored and pevma committed Jun 3, 2024
1 parent 5384255 commit 4057d5e
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion ui/app/components/EventValue/index.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import React, { useState } from 'react';

import { CopyOutlined, ZoomInOutlined, ZoomOutOutlined } from '@ant-design/icons';
import { InfoCircleFilled, CopyOutlined, ZoomInOutlined, ZoomOutOutlined } from '@ant-design/icons';
import { message } from 'antd';
import PropTypes from 'prop-types';
import styled from 'styled-components';

import TypedValue from 'ui/components/TypedValue';
import { COLOR_BOX_HEADER } from 'ui/constants/colors';
import copyTextToClipboard from 'ui/helpers/copyTextToClipboard';
import isIP from 'ui/helpers/isIP';
import { useStore } from 'ui/mobx/RootStoreProvider';
import Filter from 'ui/utils/Filter';

Expand Down Expand Up @@ -71,6 +72,17 @@ const EventValue = ({ filter, count, copyMode }) => {
</div>
),
}, // Copy text to clipboard
{
key: 'typedValueHostnameVirus',
label: (
<a
href={`https://www.virustotal.com/gui/${isIP(encodeURIComponent(filter.value)) ? 'ip-address' : 'domain'}/${filter.value}`}
target="_blank"
>
<InfoCircleFilled /> <span>External info</span>
</a>
),
},
];

return (
Expand Down

0 comments on commit 4057d5e

Please sign in to comment.