xwayland: Add an XACE property access handler
This is preparation work to restrict access to Xwayland properties. Signed-off-by: Olivier Fourdan <ofourdan@redhat.com> Reviewed-by: Daniel Stone <daniels@collabora.com> Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
This commit is contained in:
parent
411a61f571
commit
a07c2cda98
|
@ -41,6 +41,7 @@
|
||||||
#include <dixstruct.h>
|
#include <dixstruct.h>
|
||||||
#include <propertyst.h>
|
#include <propertyst.h>
|
||||||
#include <inputstr.h>
|
#include <inputstr.h>
|
||||||
|
#include <xacestr.h>
|
||||||
#include <xserver_poll.h>
|
#include <xserver_poll.h>
|
||||||
|
|
||||||
#include "xwayland-cursor.h"
|
#include "xwayland-cursor.h"
|
||||||
|
@ -166,6 +167,12 @@ xwl_property_callback(CallbackListPtr *pcbl, void *closure,
|
||||||
xwl_window_update_property(xwl_window, rec);
|
xwl_window_update_property(xwl_window, rec);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
xwl_access_property_callback(CallbackListPtr *pcbl, void *closure,
|
||||||
|
void *calldata)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
xwl_root_window_finalized_callback(CallbackListPtr *pcbl,
|
xwl_root_window_finalized_callback(CallbackListPtr *pcbl,
|
||||||
void *closure,
|
void *closure,
|
||||||
|
@ -195,6 +202,7 @@ xwl_close_screen(ScreenPtr screen)
|
||||||
xwl_dmabuf_feedback_destroy(&xwl_screen->default_feedback);
|
xwl_dmabuf_feedback_destroy(&xwl_screen->default_feedback);
|
||||||
|
|
||||||
DeleteCallback(&PropertyStateCallback, xwl_property_callback, screen);
|
DeleteCallback(&PropertyStateCallback, xwl_property_callback, screen);
|
||||||
|
XaceDeleteCallback(XACE_PROPERTY_ACCESS, xwl_access_property_callback, screen);
|
||||||
|
|
||||||
xorg_list_for_each_entry_safe(xwl_output, next_xwl_output,
|
xorg_list_for_each_entry_safe(xwl_output, next_xwl_output,
|
||||||
&xwl_screen->output_list, link)
|
&xwl_screen->output_list, link)
|
||||||
|
@ -1027,6 +1035,7 @@ xwl_screen_init(ScreenPtr pScreen, int argc, char **argv)
|
||||||
|
|
||||||
AddCallback(&PropertyStateCallback, xwl_property_callback, pScreen);
|
AddCallback(&PropertyStateCallback, xwl_property_callback, pScreen);
|
||||||
AddCallback(&RootWindowFinalizeCallback, xwl_root_window_finalized_callback, pScreen);
|
AddCallback(&RootWindowFinalizeCallback, xwl_root_window_finalized_callback, pScreen);
|
||||||
|
XaceRegisterCallback(XACE_PROPERTY_ACCESS, xwl_access_property_callback, pScreen);
|
||||||
|
|
||||||
xwl_screen_setup_custom_vector(xwl_screen);
|
xwl_screen_setup_custom_vector(xwl_screen);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue