On 20/06/16 12:58, Jan Beulich wrote:
> @@ -3845,10 +3834,11 @@ x86_emulate(
>              goto push;
>          case 7:
>              generate_exception_if(1, EXC_UD, -1);
> -        default:
> -            goto cannot_emulate;
>          }
>          break;
> +
> +    default:
> +        BUG();

These introduce DoS vulnerabilities if there is indeed a path to default.

Could I recommend instead a one-time printk() dumping the instruction
stream which lead to here, an ASSERT_UNREACHABLE(), and a goto
cannot_emulate?

That way, a production build won't crash.

~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

Reply via email to