lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Tue, 02 Sep 2014 23:52:27 +0200
From:	"Rafael J. Wysocki" <rjw@...ysocki.net>
To:	Lv Zheng <lv.zheng@...el.com>
Cc:	"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
	Len Brown <len.brown@...el.com>, Lv Zheng <zetalog@...il.com>,
	linux-kernel@...r.kernel.org, linux-acpi@...r.kernel.org,
	Mika Westerberg <mika.westerberg@...ux.intel.com>,
	Bob Moore <robert.moore@...el.com>
Subject: Re: [PATCH] ACPICA: ACPI 5.1: Add support for runtime validation of _DSD package.

On Friday, August 29, 2014 09:32:42 AM Lv Zheng wrote:
> From: Mika Westerberg <mika.westerberg@...ux.intel.com>
> 
> Adds ACPICA kernel runtime support to validate contents/format
> of the _DSD package, similar to the iASL support. Ported by
> Mika Westerberg.
> 
> Signed-off-by: Mika Westerberg <mika.westerberg@...ux.intel.com>
> Signed-off-by: Bob Moore <robert.moore@...el.com>
> Signed-off-by: Lv Zheng <lv.zheng@...el.com>

Queued up for 3.17-rc4, thanks!

> ---
>  drivers/acpi/acpica/nsprepkg.c |   39 +++++++++++++++++++++++++++++++++++++++
>  1 file changed, 39 insertions(+)
> 
> diff --git a/drivers/acpi/acpica/nsprepkg.c b/drivers/acpi/acpica/nsprepkg.c
> index 68f7258..1b13b92 100644
> --- a/drivers/acpi/acpica/nsprepkg.c
> +++ b/drivers/acpi/acpica/nsprepkg.c
> @@ -316,6 +316,45 @@ acpi_ns_check_package(struct acpi_evaluate_info *info,
>  		    acpi_ns_check_package_list(info, package, elements, count);
>  		break;
>  
> +	case ACPI_PTYPE2_UUID_PAIR:
> +
> +		/* The package must contain pairs of (UUID + type) */
> +
> +		if (count & 1) {
> +			expected_count = count + 1;
> +			goto package_too_small;
> +		}
> +
> +		while (count > 0) {
> +			status = acpi_ns_check_object_type(info, elements,
> +							   package->ret_info.
> +							   object_type1, 0);
> +			if (ACPI_FAILURE(status)) {
> +				return (status);
> +			}
> +
> +			/* Validate length of the UUID buffer */
> +
> +			if ((*elements)->buffer.length != 16) {
> +				ACPI_WARN_PREDEFINED((AE_INFO,
> +						      info->full_pathname,
> +						      info->node_flags,
> +						      "Invalid length for UUID Buffer"));
> +				return (AE_AML_OPERAND_VALUE);
> +			}
> +
> +			status = acpi_ns_check_object_type(info, elements + 1,
> +							   package->ret_info.
> +							   object_type2, 0);
> +			if (ACPI_FAILURE(status)) {
> +				return (status);
> +			}
> +
> +			elements += 2;
> +			count -= 2;
> +		}
> +		break;
> +
>  	default:
>  
>  		/* Should not get here if predefined info table is correct */
> 

-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ