{"id":965,"date":"2015-07-08T22:44:25","date_gmt":"2015-07-08T22:44:25","guid":{"rendered":"https:\/\/gosqeng.test\/?p=965"},"modified":"2019-11-28T11:49:15","modified_gmt":"2019-11-28T11:49:15","slug":"ipcheck-open-source","status":"publish","type":"post","link":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source","title":{"rendered":"New Open Source Module: IPCheck"},"content":{"rendered":"<p>We&#8217;ve just released another open-source Node.js module! IPCheck adds an efficient layer on top of ipaddr.js to make it more efficient and seamlessly handle IPv4 and IPv6 addresses. <\/p>\n<p>When passed an IP address and a CIDR block, IPCheck will quickly check whether the IP is in that range.<\/p>\n<p><strong>Check out IPCheck on <a href=\"https:\/\/github.com\/gosquared\/ipcheck\" target=\"_blank\" rel=\"noopener noreferrer\">GitHub<\/a> or <a href=\"https:\/\/www.npmjs.com\/package\/ipcheck\" target=\"_blank\" rel=\"noopener noreferrer\">npm<\/a>.<\/strong><\/p>\n<p>Detailed usage examples are documented in the README, but here are a few quick examples&#8230;<\/p>\n<pre class=\"language-javascript\">\n<code>var IPCheck = require('ipcheck');\nIPCheck.match('192.168.0.1', '192.168.0.1\/32'); \/\/= true \n\nvar ip = new IPCheck('FE80:0000:0000:0000:0202:B3FF:FE1E:8329');\nvar cidr = new IPCheck('FE80:0000:0000:0000:0202:B3FF:FE1E:8329\/128');\nip.match(cidr); \/\/= true\nip.match('invalid ip'); \/\/= false\n\nvar invalid = new IPCheck(null);\ninvalid.valid; \/\/= false<\/code><\/pre>\n<p>Enjoy!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>We&#8217;ve just released another open-source Node.js module! IPCheck adds an efficient layer on top of ipaddr.js to make it more&#8230;<\/p>\n","protected":false},"author":10,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1452],"tags":[],"class_list":["post-965","post","type-post","status-publish","format-standard","hentry","category-engineering"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v18.6 (Yoast SEO v19.0) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>New Open Source Module: IPCheck - GoSquared Blog<\/title>\n<meta name=\"description\" content=\"IPCheck is an efficient Node.js module that checks whether an IP address is in a CIDR block. It seamlessly handles IPv4 and IPv6 addresses.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"New Open Source Module: IPCheck\" \/>\n<meta property=\"og:description\" content=\"IPCheck is an efficient Node.js module that checks whether an IP address is in a CIDR block. It seamlessly handles IPv4 and IPv6 addresses.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source\" \/>\n<meta property=\"og:site_name\" content=\"GoSquared Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/GoSquared\" \/>\n<meta property=\"article:published_time\" content=\"2015-07-08T22:44:25+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2019-11-28T11:49:15+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@simon_tabor\" \/>\n<meta name=\"twitter:site\" content=\"@GoSquared\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Simon Tabor\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/#organization\",\"name\":\"GoSquared\",\"url\":\"https:\/\/www.gosquared.com\/blog\/\",\"sameAs\":[\"https:\/\/instagram.com\/gosquaredteam\",\"https:\/\/www.linkedin.com\/company\/go-squared-ltd.\",\"https:\/\/www.facebook.com\/GoSquared\",\"https:\/\/twitter.com\/GoSquared\"],\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.gosquared.com\/blog\/wp-content\/uploads\/2015\/07\/gosquared.png\",\"contentUrl\":\"https:\/\/www.gosquared.com\/blog\/wp-content\/uploads\/2015\/07\/gosquared.png\",\"width\":1270,\"height\":250,\"caption\":\"GoSquared\"},\"image\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/#website\",\"url\":\"https:\/\/www.gosquared.com\/blog\/\",\"name\":\"GoSquared Blog\",\"description\":\"Turn visitors into customers.\",\"publisher\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.gosquared.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#webpage\",\"url\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source\",\"name\":\"New Open Source Module: IPCheck - GoSquared Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/#website\"},\"datePublished\":\"2015-07-08T22:44:25+00:00\",\"dateModified\":\"2019-11-28T11:49:15+00:00\",\"description\":\"IPCheck is an efficient Node.js module that checks whether an IP address is in a CIDR block. It seamlessly handles IPv4 and IPv6 addresses.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.gosquared.com\/blog\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"New Open Source Module: IPCheck\"}]},{\"@type\":\"Article\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#webpage\"},\"author\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/#\/schema\/person\/71fad71f60ad33cf9356687b37aed3d0\"},\"headline\":\"New Open Source Module: IPCheck\",\"datePublished\":\"2015-07-08T22:44:25+00:00\",\"dateModified\":\"2019-11-28T11:49:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#webpage\"},\"wordCount\":78,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.gosquared.com\/blog\/#organization\"},\"articleSection\":[\"Engineering\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#respond\"]}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/#\/schema\/person\/71fad71f60ad33cf9356687b37aed3d0\",\"name\":\"Simon Tabor\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.gosquared.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/dc920e48608646bda51d2e6e2595e8ad926cff52eba534c1d25fb1618f15b59f?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/dc920e48608646bda51d2e6e2595e8ad926cff52eba534c1d25fb1618f15b59f?s=96&d=mm&r=g\",\"caption\":\"Simon Tabor\"},\"description\":\"Lead developer at GoSquared for integrations, partnerships and the API. Works on pretty much everything.\",\"sameAs\":[\"http:\/\/simontabor.com\",\"https:\/\/twitter.com\/simon_tabor\"],\"url\":\"https:\/\/www.gosquared.com\/blog\/author\/simontabor\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"New Open Source Module: IPCheck - GoSquared Blog","description":"IPCheck is an efficient Node.js module that checks whether an IP address is in a CIDR block. It seamlessly handles IPv4 and IPv6 addresses.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source","og_locale":"en_US","og_type":"article","og_title":"New Open Source Module: IPCheck","og_description":"IPCheck is an efficient Node.js module that checks whether an IP address is in a CIDR block. It seamlessly handles IPv4 and IPv6 addresses.","og_url":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source","og_site_name":"GoSquared Blog","article_publisher":"https:\/\/www.facebook.com\/GoSquared","article_published_time":"2015-07-08T22:44:25+00:00","article_modified_time":"2019-11-28T11:49:15+00:00","twitter_card":"summary_large_image","twitter_creator":"@simon_tabor","twitter_site":"@GoSquared","twitter_misc":{"Written by":"Simon Tabor","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Organization","@id":"https:\/\/www.gosquared.com\/blog\/#organization","name":"GoSquared","url":"https:\/\/www.gosquared.com\/blog\/","sameAs":["https:\/\/instagram.com\/gosquaredteam","https:\/\/www.linkedin.com\/company\/go-squared-ltd.","https:\/\/www.facebook.com\/GoSquared","https:\/\/twitter.com\/GoSquared"],"logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.gosquared.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.gosquared.com\/blog\/wp-content\/uploads\/2015\/07\/gosquared.png","contentUrl":"https:\/\/www.gosquared.com\/blog\/wp-content\/uploads\/2015\/07\/gosquared.png","width":1270,"height":250,"caption":"GoSquared"},"image":{"@id":"https:\/\/www.gosquared.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"WebSite","@id":"https:\/\/www.gosquared.com\/blog\/#website","url":"https:\/\/www.gosquared.com\/blog\/","name":"GoSquared Blog","description":"Turn visitors into customers.","publisher":{"@id":"https:\/\/www.gosquared.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.gosquared.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#webpage","url":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source","name":"New Open Source Module: IPCheck - GoSquared Blog","isPartOf":{"@id":"https:\/\/www.gosquared.com\/blog\/#website"},"datePublished":"2015-07-08T22:44:25+00:00","dateModified":"2019-11-28T11:49:15+00:00","description":"IPCheck is an efficient Node.js module that checks whether an IP address is in a CIDR block. It seamlessly handles IPv4 and IPv6 addresses.","breadcrumb":{"@id":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.gosquared.com\/blog\/ipcheck-open-source"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.gosquared.com\/blog"},{"@type":"ListItem","position":2,"name":"New Open Source Module: IPCheck"}]},{"@type":"Article","@id":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#article","isPartOf":{"@id":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#webpage"},"author":{"@id":"https:\/\/www.gosquared.com\/blog\/#\/schema\/person\/71fad71f60ad33cf9356687b37aed3d0"},"headline":"New Open Source Module: IPCheck","datePublished":"2015-07-08T22:44:25+00:00","dateModified":"2019-11-28T11:49:15+00:00","mainEntityOfPage":{"@id":"https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#webpage"},"wordCount":78,"commentCount":0,"publisher":{"@id":"https:\/\/www.gosquared.com\/blog\/#organization"},"articleSection":["Engineering"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.gosquared.com\/blog\/ipcheck-open-source#respond"]}]},{"@type":"Person","@id":"https:\/\/www.gosquared.com\/blog\/#\/schema\/person\/71fad71f60ad33cf9356687b37aed3d0","name":"Simon Tabor","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.gosquared.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/dc920e48608646bda51d2e6e2595e8ad926cff52eba534c1d25fb1618f15b59f?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/dc920e48608646bda51d2e6e2595e8ad926cff52eba534c1d25fb1618f15b59f?s=96&d=mm&r=g","caption":"Simon Tabor"},"description":"Lead developer at GoSquared for integrations, partnerships and the API. Works on pretty much everything.","sameAs":["http:\/\/simontabor.com","https:\/\/twitter.com\/simon_tabor"],"url":"https:\/\/www.gosquared.com\/blog\/author\/simontabor"}]}},"wps_subtitle":"Quickly validate and check IPs & CIDR blocks","_links":{"self":[{"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/posts\/965","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/users\/10"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/comments?post=965"}],"version-history":[{"count":0,"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/posts\/965\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/media?parent=965"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/categories?post=965"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gosquared.com\/blog\/wp-json\/wp\/v2\/tags?post=965"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}