Documentation
¶
Overview ¶
Copyright © 2024 Alessandro Riva
Licensed under the MIT License. See the LICENSE file for details.
Copyright © 2024 Alessandro Riva ¶
Licensed under the MIT License. See the LICENSE file for details.
Copyright © 2024 Alessandro Riva ¶
Licensed under the MIT License. See the LICENSE file for details.
Index ¶
Constants ¶
View Source
const IPInfoBaseURL = "https://ipinfo.io"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AbuseIPDBResponse ¶
type AbuseIPDBResponse struct {
Data struct {
IPAddress string `json:"ipAddress"`
IsPublic bool `json:"isPublic"`
IPVersion int `json:"ipVersion"`
IsWhitelisted bool `json:"isWhitelisted"`
AbuseConfidenceScore int `json:"abuseConfidenceScore"`
CountryCode string `json:"countryCode"`
UsageType string `json:"usageType"`
ISP string `json:"isp"`
Domain string `json:"domain"`
Hostnames []string `json:"hostnames"`
TotalReports int `json:"totalReports"`
LastReportedAt string `json:"lastReportedAt"`
Reports []struct {
ReporterID int `json:"reporterId"`
ReporterCountry string `json:"reporterCountryCode"`
ReportedAt string `json:"reportedAt"`
Comment string `json:"comment"`
} `json:"reports"`
} `json:"data"`
}
func GetAbuseIPDBInfo ¶
func GetAbuseIPDBInfo(ip net.IP, apiKey string) *AbuseIPDBResponse
getAbuseIPDBInfo fetches data from AbuseIPDB for a specific IP address
type GreyNoiseInfo ¶
type GreyNoiseInfo struct {
IP string `json:"ip"`
Noise bool `json:"noise"`
Riot bool `json:"riot"`
Classification string `json:"classification"`
Link string `json:"link"`
LastSeen string `json:"last_seen"`
Message string `json:"message"`
}
func GetGreyNoiseData ¶
func GetGreyNoiseData(ip net.IP, apiKey string) *GreyNoiseInfo
Get threat intelligence from GreyNoise API
Click to show internal directories.
Click to hide internal directories.