Lucene search

K
nessusThis script is Copyright (C) 2010-2023 Tenable Network Security, Inc.MACOSX_MS_OFFICE_AUG2010.NASL
HistoryOct 20, 2010 - 12:00 a.m.

MS10-056 / MS10-057: Vulnerabilities in Microsoft Office Could Allow Remote Code Execution (2269638 / 2269707) (Mac OS X)

2010-10-2000:00:00
This script is Copyright (C) 2010-2023 Tenable Network Security, Inc.
www.tenable.com
18

7.2 High

AI Score

Confidence

Low

The remote Mac OS X host is running a version of Microsoft Office that is affected by several vulnerabilities.

If an attacker can trick a user on the affected host into opening a specially crafted Word or Excel file, these issues could be leveraged to execute arbitrary code subject to the user’s privileges.

#TRUSTED 4061ac290216b39e1a0c2bfe7b64e65b8e0bc071a0f2c5708e8f10f87696e4a87125c22f46127996581be31eebdfde3fddaecc3d230ec8364e6d3ed47d319a48bc3df8aece449e6e65f658958ee85c88a05273cb40722a3140f6a60730f677d653850fe8bad515d6948026d4fc746bc0a21b097c43f68c9fbcb0a8d0f74cb2c35c2eca18ed7e8333016c83e10438a01c726dca60f115d6e807ad1e5a4d95739474946663f6562f8b076c47ae05f2e4a88e9a0206bf2289d3a2f0c0bbe27a99a091c2986342716ea7632b0a395e7f246d776e7a5003be0e67c48e5c77c5986bf31ff724d77d2272494fc9c3020adaafb6c592e835b079cd8e2ec363acb32279bd8c04f6f0aa6c520375f372d0429931e50e3dc09ff140cc9d36b5a58087ddcbcf9bc5ee0fe2c20ddc65022c2a6d2bbb76f2993b8fa6ff964764d9cc37c0af6c8ffc70519d36c85aab7d1568bf693861a0a97b8909104c53fbc1cf42c287f6b40239b81a56b6be0862361530847c986b20ac102dbc9f3d27bdcc6691669d0aa791eb4e10b550d555a8c880f42d29f1e57e78725dbd0e1b20f45d58f0296d112af3c9c79f033c20928b7d4d333e0488dcaa501890ea2fb5d653ece9a83324101acaafe4e89f55b40251e82fcbd21d04edb495680d80ea3b3966552b67e21abdc364723af08f1c33ff123698242d25da3ed3796fbeabcfa1375c97b040f355438e64
#TRUST-RSA-SHA256 5b2f02a7de26cfe68fa3191a5a78abb24226aa335ff705cfa0e3307227d1b1bdb6add4649590d620879f327a2b68620c3af9ad1bb560c6f9ad8f05929d9bb8347a60882c3a7be14f4cdbf2b3d17bcf1931f9e00ce9877d2169bc3b796fbab5a271a8b5a5d7339d905552842edb046f53e95d57edee300af6763b092b858f238258cc50e8706eff7a9a4535216edc11f759017f2922d3578fc8ed3ee41bd217036b97542302783aff1cc92d31d167d7a15f90d0c85f64fa2314aefbca5a997397298dbd5e1e35b37b197637c3995dee2fcffa910ec99311e3dd821cb4a6081bd79666138744cba5546b57d21dadabea402006e91970fc707bb2b09518b5b2e1f23c3215142d6f1f30dc20fa405912300f7bea5270101fb2692dbf4424e0d8c496d9b79ed5d964497a30271b8eba380d14b3f211122c9069897d9bc0b2f5a5e0e02585cda870ae0d4ff39d287c16ae9e723b68ba0126d765b5c4372f02331e7ac5bff6bac179abcfb85357deb22da1b4b2bf41fbd7d3a30e0dbb2105c59c59779cd12b513feb37a87d5e1ee5c6987603129b8f8d88a0a0c32c969e80d45bf45088fb4f00b323f367d249f2d683dab182ab16a0843023006bed07795a55b13bfcb5051d14e0444843dedd4758a679551136bdf65af7357c3d351a3871ed84d498247197718c405763604fe65aeac7d331cec19ec992b832620c950cb426426a62d6
#
# (C) Tenable Network Security, Inc.
#

include("compat.inc");

if (description)
{
  script_id(50067);
  script_version("1.22");
  script_set_attribute(attribute:"plugin_modification_date", value:"2023/11/27");

  script_cve_id("CVE-2010-1900", "CVE-2010-1901", "CVE-2010-1902", "CVE-2010-2562");
  script_bugtraq_id(42132, 42133, 42136, 42199);
  script_xref(name:"MSFT", value:"MS10-056");
  script_xref(name:"MSFT", value:"MS10-057");
  script_xref(name:"MSKB", value:"2269638");
  script_xref(name:"MSKB", value:"2269707");
  script_xref(name:"MSKB", value:"2284162");
  script_xref(name:"MSKB", value:"2284171");
  script_xref(name:"MSKB", value:"2284179");

  script_name(english:"MS10-056 / MS10-057: Vulnerabilities in Microsoft Office Could Allow Remote Code Execution (2269638 / 2269707) (Mac OS X)");
  script_summary(english:"Check version of Microsoft Office");

  script_set_attribute(attribute:"synopsis", value:
"An application installed on the remote Mac OS X host is affected by
multiple remote code execution vulnerabilities.");
  script_set_attribute(attribute:"description", value:
"The remote Mac OS X host is running a version of Microsoft Office that
is affected by several vulnerabilities.

If an attacker can trick a user on the affected host into opening a
specially crafted Word or Excel file, these issues could be leveraged
to execute arbitrary code subject to the user's privileges.");
  script_set_attribute(attribute:"see_also", value:"http://technet.microsoft.com/en-us/security/bulletin/ms10-056");
  script_set_attribute(attribute:"see_also", value:"http://technet.microsoft.com/en-us/security/bulletin/ms10-057");
  script_set_attribute(attribute:"solution", value:
"Microsoft has released a set of patches for Office 2004 for Mac,
Office 2008 for Mac, and Open XML File Format Converter for Mac.");
  script_set_cvss_base_vector("CVSS2#AV:N/AC:M/Au:N/C:C/I:C/A:C");
  script_set_cvss_temporal_vector("CVSS2#E:H/RL:OF/RC:C");
  script_set_attribute(attribute:"cvss_score_source", value:"CVE-2010-2562");
  script_set_attribute(attribute:"exploitability_ease", value:"Exploits are available");
  script_set_attribute(attribute:"exploit_available", value:"true");
  script_set_attribute(attribute:"exploited_by_malware", value:"true");
  script_set_attribute(attribute:"exploit_framework_core", value:"true");

  script_set_attribute(attribute:"vuln_publication_date", value:"2010/08/10");
  script_set_attribute(attribute:"patch_publication_date", value:"2010/08/10");
  script_set_attribute(attribute:"plugin_publication_date", value:"2010/10/20");

  script_set_attribute(attribute:"plugin_type", value:"local");
  script_set_attribute(attribute:"cpe", value:"cpe:/a:microsoft:office:2004::mac");
  script_set_attribute(attribute:"cpe", value:"cpe:/a:microsoft:office:2008::mac");
  script_set_attribute(attribute:"cpe", value:"cpe:/a:microsoft:open_xml_file_format_converter:::mac");
  script_end_attributes();

  script_category(ACT_GATHER_INFO);
  script_family(english:"MacOS X Local Security Checks");

  script_copyright(english:"This script is Copyright (C) 2010-2023 Tenable Network Security, Inc.");

  script_dependencies("ssh_get_info.nasl");
  script_require_keys("Host/MacOSX/packages", "Host/uname");

  exit(0);
}


include("misc_func.inc");
include("ssh_func.inc");
include("macosx_func.inc");



enable_ssh_wrappers();

function exec(cmd)
{
  local_var buf, ret;

  if (islocalhost())
    buf = pread_wrapper(cmd:"/bin/bash", argv:make_list("bash", "-c", cmd));
  else
  {
    ret = ssh_open_connection();
    if (!ret) exit(1, "ssh_open_connection() failed.");
    buf = ssh_cmd(cmd:cmd);
    ssh_close_connection();
  }
  return buf;
}


packages = get_kb_item("Host/MacOSX/packages");
if (!packages) exit(1, "The 'Host/MacOSX/packages' KB item is missing.");

uname = get_kb_item("Host/uname");
if (!uname) exit(1, "The 'Host/uname' KB item is missing.");
if (!egrep(pattern:"Darwin.*", string:uname)) exit(1, "The host does not appear to be using the Darwin sub-system.");


# Gather version info.
info = '';
installs = make_array();

prod = 'Office 2008 for Mac';
plist = "/Applications/Microsoft Office 2008/Office/MicrosoftComponentPlugin.framework/Versions/12/Resources/Info.plist";
cmd =  'cat \'' + plist + '\' | ' +
  'grep -A 1 CFBundleShortVersionString | ' +
  'tail -n 1 | ' +
  'sed \'s/.*string>\\(.*\\)<\\/string>.*/\\1/g\'';
version = exec(cmd:cmd);
if (version && version =~ "^[0-9]+\.")
{
  version = chomp(version);
  if (version !~ "^12\.") exit(1, "Failed to get the version for "+prod+" - '"+version+"'.");

  installs[prod] = version;

  ver = split(version, sep:'.', keep:FALSE);
  for (i=0; i<max_index(ver); i++)
    ver[i] = int(ver[i]);

  fixed_version = '12.2.6';
  fix = split(fixed_version, sep:'.', keep:FALSE);
  for (i=0; i<max_index(fix); i++)
    fix[i] = int(fix[i]);

  for (i=0; i<max_index(fix); i++)
    if ((ver[i] < fix[i]))
    {
      info +=
        '\n  Product           : ' + prod +
        '\n  Installed version : ' + version +
        '\n  Fixed version     : ' + fixed_version + '\n';
      break;
    }
    else if (ver[i] > fix[i])
      break;
}

prod = 'Office 2004 for Mac';
cmd = GetCarbonVersionCmd(file:"Microsoft Component Plugin", path:"/Applications/Microsoft Office 2004/Office");
version = exec(cmd:cmd);
if (version && version =~ "^[0-9]+\.")
{
  version = chomp(version);
  if (version !~ "^11\.") exit(1, "Failed to get the version for "+prod+" - '"+version+"'.");

  installs[prod] = version;

  ver = split(version, sep:'.', keep:FALSE);
  for (i=0; i<max_index(ver); i++)
    ver[i] = int(ver[i]);

  fixed_version = '11.6.0';
  fix = split(fixed_version, sep:'.', keep:FALSE);
  for (i=0; i<max_index(fix); i++)
    fix[i] = int(fix[i]);

  for (i=0; i<max_index(fix); i++)
    if ((ver[i] < fix[i]))
    {
      info +=
        '\n  Product           : ' + prod +
        '\n  Installed version : ' + version +
        '\n  Fixed version     : ' + fixed_version + '\n';
      break;
    }
    else if (ver[i] > fix[i])
      break;
}

prod = 'Open XML File Format Converter for Mac';
plist = "/Applications/Open XML Converter.app/Contents/Info.plist";
cmd =  'cat \'' + plist + '\' | ' +
  'grep -A 1 CFBundleShortVersionString | ' +
  'tail -n 1 | ' +
  'sed \'s/.*string>\\(.*\\)<\\/string>.*/\\1/g\'';
version = exec(cmd:cmd);
if (version && version =~ "^[0-9]+\.")
{
  version = chomp(version);
  installs[prod] = version;

  ver = split(version, sep:'.', keep:FALSE);
  for (i=0; i<max_index(ver); i++)
    ver[i] = int(ver[i]);

  fixed_version = '1.1.6';
  fix = split(fixed_version, sep:'.', keep:FALSE);
  for (i=0; i<max_index(fix); i++)
    fix[i] = int(fix[i]);

  for (i=0; i<max_index(fix); i++)
    if ((ver[i] < fix[i]))
    {
      info +=
        '\n  Product           : ' + prod +
        '\n  Installed version : ' + version +
        '\n  Fixed version     : ' + fixed_version + '\n';
      break;
    }
    else if (ver[i] > fix[i])
      break;
}


# Report findings.
if (info)
{
  gs_opt = get_kb_item("global_settings/report_verbosity");
  if (gs_opt && gs_opt != 'Quiet') security_hole(port:0, extra:info);
  else security_hole(0);

  exit(0);
}
else
{
  if (max_index(keys(installs)) == 0) exit(0, "Office for Mac / Open XML File Format Converter is not installed.");
  else
  {
    msg = 'The host has ';
    foreach prod (sort(keys(installs)))
      msg += prod + ' ' + installs[prod] + ' and ';
    msg = substr(msg, 0, strlen(msg)-1-strlen(' and '));

    msg += ' installed and thus is not affected.';

    exit(0, msg);
  }
}
VendorProductVersionCPE
microsoftoffice2004cpe:/a:microsoft:office:2004::mac
microsoftoffice2008cpe:/a:microsoft:office:2008::mac
microsoftopen_xml_file_format_convertercpe:/a:microsoft:open_xml_file_format_converter:::mac