MySQL 8.4.2
Source Code Documentation
event_tracking_authentication_defs.h
Go to the documentation of this file.
1/* Copyright (c) 2022, 2024, Oracle and/or its affiliates.
2
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License, version 2.0,
5 as published by the Free Software Foundation.
6
7 This program is designed to work with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have either included with
13 the program or referenced in the documentation.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License, version 2.0, for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
23
24#ifndef COMPONENTS_SERVICES_DEFS_EVENT_TRACKING_AUTHENTICATION_DEFS_H
25#define COMPONENTS_SERVICES_DEFS_EVENT_TRACKING_AUTHENTICATION_DEFS_H
26
28
29/**
30 @file mysql/components/services/defs/event_tracking_authentication_defs.h
31 Data for authentication event tracking.
32
33 This files defines following:
34 A. Possible subevents of authentication events
35 B. Information provided by producers of the event when
36 authentication events are generated.
37
38 @sa @ref EVENT_TRACKING_AUTHENTICATION_SERVICE
39*/
40
41/** Generated after FLUSH PRIVILEGES */
42#define EVENT_TRACKING_AUTHENTICATION_FLUSH (1 << 0)
43/** Generated after CREATE USER | CREATE ROLE */
44#define EVENT_TRACKING_AUTHENTICATION_AUTHID_CREATE (1 << 1)
45/**
46 Generated after credential change through:
47 - SET PASSWORD
48 - ALTER USER
49 - GRANT
50*/
51#define EVENT_TRACKING_AUTHENTICATION_CREDENTIAL_CHANGE (1 << 2)
52/** Generated after RENAME USER */
53#define EVENT_TRACKING_AUTHENTICATION_AUTHID_RENAME (1 << 3)
54/** Generated after DROP USER */
55#define EVENT_TRACKING_AUTHENTICATION_AUTHID_DROP (1 << 4)
56
57#define EVENT_TRACKING_AUTHENTICATION_ALL \
58 EVENT_TRACKING_AUTHENTICATION_FLUSH | \
59 EVENT_TRACKING_AUTHENTICATION_AUTHID_CREATE | \
60 EVENT_TRACKING_AUTHENTICATION_CREDENTIAL_CHANGE | \
61 EVENT_TRACKING_AUTHENTICATION_AUTHID_RENAME | \
62 EVENT_TRACKING_AUTHENTICATION_AUTHID_DROP
63
64/**
65 @typedef mysql_event_tracking_authentication_subclass_t
66
67 Events for Authentication event tracking
68
69 Event handler can not terminate an event unless stated
70 explicitly.
71*/
73
74/**
75 @struct mysql_event_tracking_authentication_data
76
77 Structure for Authentication event tracking.
78*/
80 /** Event subclass. */
82 /** Event status */
83 int status;
84 /** Connection id. */
86 /** User name */
88 /** Host name */
90};
91
92#endif // !COMPONENTS_SERVICES_DEFS_EVENT_TRACKING_AUTHENTICATION_DEFS_H
unsigned long mysql_event_tracking_authentication_subclass_t
Events for Authentication event tracking.
Definition: event_tracking_authentication_defs.h:72
Common data used for tracking various types of events.
unsigned long mysql_connection_id
Connection Identifier.
Definition: event_tracking_common_defs.h:46
String with length information.
Definition: mysql_string_defs.h:33
Structure for Authentication event tracking.
Definition: event_tracking_authentication_defs.h:79
mysql_cstring_with_length host
Host name.
Definition: event_tracking_authentication_defs.h:89
mysql_connection_id connection_id
Connection id.
Definition: event_tracking_authentication_defs.h:85
mysql_event_tracking_authentication_subclass_t event_subclass
Event subclass.
Definition: event_tracking_authentication_defs.h:81
int status
Event status.
Definition: event_tracking_authentication_defs.h:83
mysql_cstring_with_length user
User name.
Definition: event_tracking_authentication_defs.h:87