ping.go 1014 B

123456789101112131415161718192021
  1. package data
  2. import (
  3. "github.com/scraperwall/asndb"
  4. "github.com/scraperwall/geoip"
  5. )
  6. // Ping is used as a primitive way to validate that a browser has JS
  7. type Ping struct {
  8. Timestamp int64 `bson:"timestamp" json:"timestamp" form:"timestamp"`
  9. Checksum string `bson:"checksum" json:"checksum" form:"checksum"`
  10. Remote string `bson:"remote" json:"remote" form:"remote"`
  11. URL string `bson:"url" json:"url" form:"url"`
  12. Source string `bson:"source" json:"source" form:"source"`
  13. XForwardedFor string `bson:"x_forwarded_for" json:"x-forwarded-for" form:"x_forwarded_for"`
  14. XRealIP string `bson:"x_real_ip" json:"x-real-ip" form:"x_real_ip"`
  15. XScwIP string `bson:"x_scw_ip" json:"x-scw-ip" form:"x_scw_ip"`
  16. ASN *asndb.ASN `bson:"asn" json:"asn" form:"asn"`
  17. GeoIP *geoip.GeoIP `bson:"geoip" json:"geoip" form:"geoip"`
  18. ClientID string `bson:"clientid" json:"clientid" form:"clientid"`
  19. }