Class: MaxMind::GeoIP2::Record::Anonymizer
- Inherits:
-
Abstract
- Object
- Abstract
- MaxMind::GeoIP2::Record::Anonymizer
- Defined in:
- lib/maxmind/geoip2/record/anonymizer.rb
Overview
Contains data indicating whether an IP address is part of an anonymizing network.
This record is returned by the Insights web service.
Instance Attribute Summary collapse
-
#residential ⇒ MaxMind::GeoIP2::Record::AnonymizerFeed
readonly
Residential proxy data for the network.
Instance Method Summary collapse
-
#anonymous? ⇒ Boolean
This is true if the IP address belongs to any sort of anonymous network.
-
#anonymous_vpn? ⇒ Boolean
This is true if the IP address is registered to an anonymous VPN provider.
-
#confidence ⇒ Integer?
A score ranging from 1 to 99 that represents our percent confidence that the network is currently part of an actively used VPN service.
-
#hosting_provider? ⇒ Boolean
This is true if the IP address belongs to a hosting or VPN provider (see description of the anonymous_vpn? property).
-
#network_last_seen ⇒ Date?
The last day that the network was sighted in our analysis of anonymized networks.
-
#provider_name ⇒ String?
The name of the VPN provider (e.g., nordvpn, surfshark) associated with the network.
-
#public_proxy? ⇒ Boolean
This is true if the IP address belongs to a public proxy.
-
#residential_proxy? ⇒ Boolean
This is true if the IP address is on a suspected anonymizing network and belongs to a residential ISP.
-
#tor_exit_node? ⇒ Boolean
This is true if the IP address is a Tor exit node.
Instance Attribute Details
#residential ⇒ MaxMind::GeoIP2::Record::AnonymizerFeed (readonly)
Residential proxy data for the network. This may be populated even when no other anonymizer attributes are set. This property is only available from Insights.
20 21 22 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 20 def residential @residential end |
Instance Method Details
#anonymous? ⇒ Boolean
This is true if the IP address belongs to any sort of anonymous network. This property is only available from Insights.
42 43 44 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 42 def anonymous? get('is_anonymous') end |
#anonymous_vpn? ⇒ Boolean
This is true if the IP address is registered to an anonymous VPN provider. If a VPN provider does not register subnets under names associated with them, we will likely only flag their IP ranges using the hosting_provider? property. This property is only available from Insights.
53 54 55 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 53 def anonymous_vpn? get('is_anonymous_vpn') end |
#confidence ⇒ Integer?
A score ranging from 1 to 99 that represents our percent confidence that the network is currently part of an actively used VPN service. This property is only available from Insights.
34 35 36 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 34 def confidence get('confidence') end |
#hosting_provider? ⇒ Boolean
This is true if the IP address belongs to a hosting or VPN provider (see description of the anonymous_vpn? property). This property is only available from Insights.
62 63 64 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 62 def hosting_provider? get('is_hosting_provider') end |
#network_last_seen ⇒ Date?
The last day that the network was sighted in our analysis of anonymized networks. This value is parsed lazily. This property is only available from Insights.
97 98 99 100 101 102 103 104 105 106 107 108 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 97 def network_last_seen return @network_last_seen if defined?(@network_last_seen) date_string = get('network_last_seen') if !date_string @network_last_seen = nil return nil end @network_last_seen = Date.parse(date_string) end |
#provider_name ⇒ String?
The name of the VPN provider (e.g., nordvpn, surfshark) associated with the network. This property is only available from Insights.
115 116 117 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 115 def provider_name get('provider_name') end |
#public_proxy? ⇒ Boolean
This is true if the IP address belongs to a public proxy. This property is only available from Insights.
70 71 72 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 70 def public_proxy? get('is_public_proxy') end |
#residential_proxy? ⇒ Boolean
This is true if the IP address is on a suspected anonymizing network and belongs to a residential ISP. This property is only available from Insights.
79 80 81 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 79 def residential_proxy? get('is_residential_proxy') end |
#tor_exit_node? ⇒ Boolean
This is true if the IP address is a Tor exit node. This property is only available from Insights.
87 88 89 |
# File 'lib/maxmind/geoip2/record/anonymizer.rb', line 87 def tor_exit_node? get('is_tor_exit_node') end |