ID OPENVAS:1361412562310105168 Type openvas Reporter This script is Copyright (C) 2015 Greenbone Networks GmbH Modified 2019-02-18T00:00:00
Description
The script attempts to identify an Snom devices via SIP banner
###############################################################################
# OpenVAS Vulnerability Test
# $Id: gb_snom_detect.nasl 13734 2019-02-18 11:03:47Z cfischer $
#
# Snom Detection (SIP)
#
# Authors:
# Michael Meyer <michael.meyer@greenbone.net>
#
# Copyright:
# Copyright (c) 2015 Greenbone Networks GmbH
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
###############################################################################
if(description)
{
script_oid("1.3.6.1.4.1.25623.1.0.105168");
script_version("$Revision: 13734 $");
script_tag(name:"last_modification", value:"$Date: 2019-02-18 12:03:47 +0100 (Mon, 18 Feb 2019) $");
script_tag(name:"creation_date", value:"2015-01-14 11:10:30 +0100 (Wed, 14 Jan 2015)");
script_tag(name:"cvss_base", value:"0.0");
script_tag(name:"cvss_base_vector", value:"AV:N/AC:L/Au:N/C:N/I:N/A:N");
script_name("Snom Detection (SIP)");
script_category(ACT_GATHER_INFO);
script_family("Product detection");
script_copyright("This script is Copyright (C) 2015 Greenbone Networks GmbH");
script_dependencies("sip_detection.nasl");
script_mandatory_keys("sip/banner/available");
script_tag(name:"summary", value:"The script attempts to identify an Snom devices via SIP banner");
script_tag(name:"qod_type", value:"remote_banner");
exit(0);
}
include("host_details.inc");
include("sip.inc");
infos = sip_get_port_proto( default_port:"5060", default_proto:"udp" );
port = infos['port'];
proto = infos['proto'];
banner = sip_get_banner( port:port, proto:proto );
if( ! banner || "snom" >!< banner )
exit( 0 );
set_kb_item(name: "snom/detected", value: TRUE);
set_kb_item(name: "snom/sip/port", value: port);
set_kb_item(name: "snom/sip/" + port + "/proto", value: proto);
set_kb_item(name: "snom/sip/" + port + "/" + proto + "/concluded", value: banner);
model_version = eregmatch( pattern:'snom([0-9]*)/([^\r\n]+)', string:banner );
if( ! isnull( model_version[1] ) && model_version[1] != "" )
set_kb_item( name:"snom/sip/" + port + "/model", value:model_version[1] );
if( ! isnull( model_version[2] ) )
set_kb_item( name:"snom/sip/" + port + "/version", value:model_version[2] );
exit( 0 );
{"bulletinFamily": "scanner", "viewCount": 2, "naslFamily": "Product detection", "reporter": "This script is Copyright (C) 2015 Greenbone Networks GmbH", "references": [], "description": "The script attempts to identify an Snom devices via SIP banner", "hashmap": [{"key": "bulletinFamily", "hash": "bbdaea376f500d25f6b0c1050311dd07"}, {"key": "cvelist", "hash": "d41d8cd98f00b204e9800998ecf8427e"}, {"key": "cvss", "hash": "8cd4821cb504d25572038ed182587d85"}, {"key": "description", "hash": "8ef23e32488aa54b547195510bf94231"}, {"key": "href", "hash": "598c39c78745fad899ebfed73152abea"}, {"key": "modified", "hash": "c82a7e7e799c4141ec3fd64fc4b19be7"}, {"key": "naslFamily", "hash": "57c29ba219a015e20011ca8641b51476"}, {"key": "pluginID", "hash": "588468e9f09d6afb27bbc116c327dd18"}, {"key": "published", "hash": "0577dabef33b05ebbbd75b827fdef1de"}, {"key": "references", "hash": "d41d8cd98f00b204e9800998ecf8427e"}, {"key": "reporter", "hash": "d12a43f7203701a9e337af12e85016f4"}, {"key": "sourceData", "hash": "fba0e97c3b36255cf44c797b749853b6"}, {"key": "title", "hash": "0d7f437d72e30845ac4a01871cda4e89"}, {"key": "type", "hash": "47c1f692ea47a21f716dad07043ade01"}], "href": "http://plugins.openvas.org/nasl.php?oid=1361412562310105168", "modified": "2019-02-18T00:00:00", "objectVersion": "1.3", "enchantments": {"dependencies": {"references": [], "modified": "2019-02-19T13:03:16"}, "score": {"value": 0.4, "vector": "NONE", "modified": "2019-02-19T13:03:16"}, "vulnersScore": 0.4}, "id": "OPENVAS:1361412562310105168", "title": "Snom Detection (SIP)", "hash": "f44cf073889ae36c5f2cfa77ef87ea8d9d568b418d8bfb6008c5b93af56ef167", "edition": 3, "published": "2015-01-14T00:00:00", "type": "openvas", "history": [{"bulletin": {"bulletinFamily": "scanner", "cvelist": [], "cvss": {"score": 0.0, "vector": "NONE"}, "description": "The script attempts to identify an Snom devices via SIP banner", "edition": 2, "enchantments": {"dependencies": {"modified": "2019-02-18T12:43:55", "references": []}, "score": {"value": 7.5, "vector": "NONE"}}, "hash": "6f494766fc3a83eb5bd470d06ecddb6c4d6a3cfdf2d0a8c2a6bfb318337b8686", "hashmap": [{"hash": "0577dabef33b05ebbbd75b827fdef1de", "key": "published"}, {"hash": "8ef23e32488aa54b547195510bf94231", "key": "description"}, {"hash": "57c29ba219a015e20011ca8641b51476", "key": "naslFamily"}, {"hash": "8143974697285c568afc154c2a7b0777", "key": "sourceData"}, {"hash": "d41d8cd98f00b204e9800998ecf8427e", "key": "references"}, {"hash": "588468e9f09d6afb27bbc116c327dd18", "key": "pluginID"}, {"hash": "c82a7e7e799c4141ec3fd64fc4b19be7", "key": "modified"}, {"hash": "0d7f437d72e30845ac4a01871cda4e89", "key": "title"}, {"hash": "598c39c78745fad899ebfed73152abea", "key": "href"}, {"hash": "d41d8cd98f00b204e9800998ecf8427e", "key": "cvelist"}, {"hash": "d12a43f7203701a9e337af12e85016f4", "key": "reporter"}, {"hash": "47c1f692ea47a21f716dad07043ade01", "key": "type"}, {"hash": "8cd4821cb504d25572038ed182587d85", "key": "cvss"}, {"hash": "bbdaea376f500d25f6b0c1050311dd07", "key": "bulletinFamily"}], "history": [], "href": "http://plugins.openvas.org/nasl.php?oid=1361412562310105168", "id": "OPENVAS:1361412562310105168", "lastseen": "2019-02-18T12:43:55", "modified": "2019-02-18T00:00:00", "naslFamily": "Product detection", "objectVersion": "1.3", "pluginID": "1361412562310105168", "published": "2015-01-14T00:00:00", "references": [], "reporter": "This script is Copyright (C) 2015 Greenbone Networks GmbH", "sourceData": "###############################################################################\n# OpenVAS Vulnerability Test\n# $Id: gb_snom_detect.nasl 13720 2019-02-18 07:43:24Z cfischer $\n#\n# Snom Detection (SIP)\n#\n# Authors:\n# Michael Meyer <michael.meyer@greenbone.net>\n#\n# Copyright:\n# Copyright (c) 2015 Greenbone Networks GmbH\n#\n# This program is free software; you can redistribute it and/or\n# modify it under the terms of the GNU General Public License\n# as published by the Free Software Foundation; either version 2\n# of the License, or (at your option) any later version\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU General Public License for more details.\n#\n# You should have received a copy of the GNU General Public License\n# along with this program; if not, write to the Free Software\n# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.\n###############################################################################\n\nif(description)\n{\n script_oid(\"1.3.6.1.4.1.25623.1.0.105168\");\n script_version(\"$Revision: 13720 $\");\n script_tag(name:\"last_modification\", value:\"$Date: 2019-02-18 08:43:24 +0100 (Mon, 18 Feb 2019) $\");\n script_tag(name:\"creation_date\", value:\"2015-01-14 11:10:30 +0100 (Wed, 14 Jan 2015)\");\n script_tag(name:\"cvss_base\", value:\"0.0\");\n script_tag(name:\"cvss_base_vector\", value:\"AV:N/AC:L/Au:N/C:N/I:N/A:N\");\n script_name(\"Snom Detection (SIP)\");\n script_category(ACT_GATHER_INFO);\n script_family(\"Product detection\");\n script_copyright(\"This script is Copyright (C) 2015 Greenbone Networks GmbH\");\n script_dependencies(\"sip_detection.nasl\", \"find_service.nasl\");\n script_mandatory_keys(\"sip/detected\");\n\n script_tag(name:\"summary\", value:\"The script attempts to identify an Snom devices via SIP banner\");\n\n script_tag(name:\"qod_type\", value:\"remote_banner\");\n\n exit(0);\n}\n\ninclude(\"host_details.inc\");\ninclude(\"sip.inc\");\n\ninfos = get_sip_port_proto( default_port:\"5060\", default_proto:\"udp\" );\nport = infos['port'];\nproto = infos['proto'];\n\nbanner = get_sip_banner( port:port, proto:proto );\nif( ! banner || \"snom\" >!< banner )\n exit( 0 );\n\nset_kb_item(name: \"snom/detected\", value: TRUE);\nset_kb_item(name: \"snom/sip/port\", value: port);\nset_kb_item(name: \"snom/sip/\" + port + \"/proto\", value: proto);\nset_kb_item(name: \"snom/sip/\" + port + \"/\" + proto + \"/concluded\", value: banner);\n\nmodel_version = eregmatch( pattern:'snom([0-9]*)/([^\\r\\n]+)', string:banner );\n\nif( ! isnull( model_version[1] ) && model_version[1] != \"\" )\n set_kb_item( name:\"snom/sip/\" + port + \"/model\", value:model_version[1] );\n\nif( ! isnull( model_version[2] ) )\n set_kb_item( name:\"snom/sip/\" + port + \"/version\", value:model_version[2] );\n\nexit( 0 );", "title": "Snom Detection (SIP)", "type": "openvas", "viewCount": 0}, "differentElements": ["sourceData"], "edition": 2, "lastseen": "2019-02-18T12:43:55"}, {"bulletin": {"bulletinFamily": "scanner", "cvelist": [], "cvss": {"score": 0.0, "vector": "NONE"}, "description": "The script sends a connection\n request to the server and attempts to extract the version number from the reply.", "edition": 1, "enchantments": {"dependencies": {"modified": "2017-07-02T21:09:10", "references": []}, "score": {"value": 7.5, "vector": "NONE"}}, "hash": "1bceecf947e36c98a63ebbf4cb1d991a3b7d9334e5fe4c13d1d4eaaacd07ce00", "hashmap": [{"hash": "0577dabef33b05ebbbd75b827fdef1de", "key": "published"}, {"hash": "57c29ba219a015e20011ca8641b51476", "key": "naslFamily"}, {"hash": "d41d8cd98f00b204e9800998ecf8427e", "key": "references"}, {"hash": "cc5b48c4d458503ec1a8bb6c18b86da6", "key": "title"}, {"hash": "588468e9f09d6afb27bbc116c327dd18", "key": "pluginID"}, {"hash": "598c39c78745fad899ebfed73152abea", "key": "href"}, {"hash": "73ba5c1fca79aa1e0d79d6e773721045", "key": "modified"}, {"hash": "d41d8cd98f00b204e9800998ecf8427e", "key": "cvelist"}, {"hash": "28825134997a64cf351a57420db9fdc6", "key": "description"}, {"hash": "d12a43f7203701a9e337af12e85016f4", "key": "reporter"}, {"hash": "47c1f692ea47a21f716dad07043ade01", "key": "type"}, {"hash": "8cd4821cb504d25572038ed182587d85", "key": "cvss"}, {"hash": "bbdaea376f500d25f6b0c1050311dd07", "key": "bulletinFamily"}, {"hash": "cca47ddbc35e87b405e779c84c7f8561", "key": "sourceData"}], "history": [], "href": "http://plugins.openvas.org/nasl.php?oid=1361412562310105168", "id": "OPENVAS:1361412562310105168", "lastseen": "2017-07-02T21:09:10", "modified": "2016-12-30T00:00:00", "naslFamily": "Product detection", "objectVersion": "1.3", "pluginID": "1361412562310105168", "published": "2015-01-14T00:00:00", "references": [], "reporter": "This script is Copyright (C) 2015 Greenbone Networks GmbH", "sourceData": "###############################################################################\n# OpenVAS Vulnerability Test\n# $Id: gb_snom_detect.nasl 4893 2016-12-30 15:49:57Z cfi $\n#\n# Snom Detection\n#\n# Authors:\n# Michael Meyer <michael.meyer@greenbone.net>\n#\n# Copyright:\n# Copyright (c) 2015 Greenbone Networks GmbH\n#\n# This program is free software; you can redistribute it and/or\n# modify it under the terms of the GNU General Public License\n# as published by the Free Software Foundation; either version 2\n# of the License, or (at your option) any later version\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU General Public License for more details.\n#\n# You should have received a copy of the GNU General Public License\n# along with this program; if not, write to the Free Software\n# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.\n###############################################################################\n\nif(description)\n{\n script_oid(\"1.3.6.1.4.1.25623.1.0.105168\");\n script_version(\"$Revision: 4893 $\");\n script_tag(name:\"last_modification\", value:\"$Date: 2016-12-30 16:49:57 +0100 (Fri, 30 Dec 2016) $\");\n script_tag(name:\"creation_date\", value:\"2015-01-14 11:10:30 +0100 (Wed, 14 Jan 2015)\");\n script_tag(name:\"cvss_base\", value:\"0.0\");\n script_tag(name:\"cvss_base_vector\", value:\"AV:N/AC:L/Au:N/C:N/I:N/A:N\");\n script_name(\"Snom Detection\");\n script_category(ACT_GATHER_INFO);\n script_family(\"Product detection\");\n script_copyright(\"This script is Copyright (C) 2015 Greenbone Networks GmbH\");\n script_dependencies(\"sip_detection.nasl\", \"find_service.nasl\");\n script_mandatory_keys(\"sip/detected\");\n\n script_tag(name:\"summary\", value:\"The script sends a connection\n request to the server and attempts to extract the version number from the reply.\");\n\n script_tag(name:\"qod_type\", value:\"remote_banner\");\n\n exit(0);\n}\n\ninclude(\"host_details.inc\");\ninclude(\"sip.inc\");\n\ninfos = get_sip_port_proto( default_port:\"5060\", default_proto:\"udp\" );\nport = infos['port'];\nproto = infos['proto'];\n\nbanner = get_sip_banner( port:port, proto:proto );\nif( ! banner || \"snom\" >!< banner ) exit( 0 );\n\nmodel = 'Unknown Model';\nversion = 'unknown';\ncpe = 'cpe:/h:snom';\n\nset_kb_item( name:\"snom/installed\", value:TRUE );\n\nmodel_version = eregmatch( pattern:'snom([0-9]*)/([^\\r\\n]+)', string:banner );\n\nif( ! isnull( model_version[1] ) && model_version[1] != \"\" ) {\n model = model_version[1];\n cpe += ':snom_' + model;\n set_kb_item( name:\"snom/model\", value:model );\n} else {\n cpe += ':snom_unknown_model';\n}\n\nif( ! isnull( model_version[2] ) ) {\n version = model_version[2];\n cpe += ':' + version;\n set_kb_item( name:\"snom/version\", value:version );\n}\n\nlocation = port + \"/\" + proto;\n\nregister_product( cpe:cpe, port:port, location:location, service:\"sip\", proto:proto );\n\nlog_message( data:build_detection_report( app:\"Snom \" + model,\n version:version,\n install:location,\n cpe:cpe,\n concluded:banner ),\n port:port,\n proto:proto );\n\nexit( 0 );\n", "title": "Snom Detection", "type": "openvas", "viewCount": 0}, "differentElements": ["description", "modified", "sourceData", "title"], "edition": 1, "lastseen": "2017-07-02T21:09:10"}], "cvss": {"score": 0.0, "vector": "NONE"}, "cvelist": [], "lastseen": "2019-02-19T13:03:16", "sourceData": "###############################################################################\n# OpenVAS Vulnerability Test\n# $Id: gb_snom_detect.nasl 13734 2019-02-18 11:03:47Z cfischer $\n#\n# Snom Detection (SIP)\n#\n# Authors:\n# Michael Meyer <michael.meyer@greenbone.net>\n#\n# Copyright:\n# Copyright (c) 2015 Greenbone Networks GmbH\n#\n# This program is free software; you can redistribute it and/or\n# modify it under the terms of the GNU General Public License\n# as published by the Free Software Foundation; either version 2\n# of the License, or (at your option) any later version\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU General Public License for more details.\n#\n# You should have received a copy of the GNU General Public License\n# along with this program; if not, write to the Free Software\n# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.\n###############################################################################\n\nif(description)\n{\n script_oid(\"1.3.6.1.4.1.25623.1.0.105168\");\n script_version(\"$Revision: 13734 $\");\n script_tag(name:\"last_modification\", value:\"$Date: 2019-02-18 12:03:47 +0100 (Mon, 18 Feb 2019) $\");\n script_tag(name:\"creation_date\", value:\"2015-01-14 11:10:30 +0100 (Wed, 14 Jan 2015)\");\n script_tag(name:\"cvss_base\", value:\"0.0\");\n script_tag(name:\"cvss_base_vector\", value:\"AV:N/AC:L/Au:N/C:N/I:N/A:N\");\n script_name(\"Snom Detection (SIP)\");\n script_category(ACT_GATHER_INFO);\n script_family(\"Product detection\");\n script_copyright(\"This script is Copyright (C) 2015 Greenbone Networks GmbH\");\n script_dependencies(\"sip_detection.nasl\");\n script_mandatory_keys(\"sip/banner/available\");\n\n script_tag(name:\"summary\", value:\"The script attempts to identify an Snom devices via SIP banner\");\n\n script_tag(name:\"qod_type\", value:\"remote_banner\");\n\n exit(0);\n}\n\ninclude(\"host_details.inc\");\ninclude(\"sip.inc\");\n\ninfos = sip_get_port_proto( default_port:\"5060\", default_proto:\"udp\" );\nport = infos['port'];\nproto = infos['proto'];\n\nbanner = sip_get_banner( port:port, proto:proto );\nif( ! banner || \"snom\" >!< banner )\n exit( 0 );\n\nset_kb_item(name: \"snom/detected\", value: TRUE);\nset_kb_item(name: \"snom/sip/port\", value: port);\nset_kb_item(name: \"snom/sip/\" + port + \"/proto\", value: proto);\nset_kb_item(name: \"snom/sip/\" + port + \"/\" + proto + \"/concluded\", value: banner);\n\nmodel_version = eregmatch( pattern:'snom([0-9]*)/([^\\r\\n]+)', string:banner );\n\nif( ! isnull( model_version[1] ) && model_version[1] != \"\" )\n set_kb_item( name:\"snom/sip/\" + port + \"/model\", value:model_version[1] );\n\nif( ! isnull( model_version[2] ) )\n set_kb_item( name:\"snom/sip/\" + port + \"/version\", value:model_version[2] );\n\nexit( 0 );", "pluginID": "1361412562310105168", "scheme": null}