Commit Graph
100 Commits
Author SHA1 Message Date
Spp 16a51e328a Update LoggingHOWTO with latest changes 2013-11-08 09:13:07 +01:00
Spp 1b04bec290 Core/Logs: Create default set of loggers and Appender if the config is wrong.
- Logger root (Error)
- Logger server (Info)
- Appender Console

Logger names are case-sensitive, Appender names are not.
2013-11-08 08:55:10 +01:00
Spp 8aa9745c4c Core/Logging: Extend logging system to allow inheritance of loggers
- Changed default loggers and appenders
- '.' determines the relation between loggers ("type.subtype" inherits "type" logger setting if logger "type.subtype" is not defined)
- When core logs a message it search for the correct logger (root is the default one)
  ie: a message logged with "type.subtype"
  * Core will try to find a logger with name "type.subtype", if its not found then will search for "type", again if its not found it will return the default one "root"
2013-11-07 16:34:44 +01:00
Spp 0c0ff98344 Core/RBAC: Fix errors in RBAC sql related to ea2fe0217d 2013-09-30 11:55:51 +02:00
Spp ad29676c27 Fix compile under linux and update auth db with latest changes 2013-09-29 14:15:58 +02:00
Spp ea2fe0217d Core/RBAC: Simplify RBAC implementation
- Drop groups (roles than can have inherited roles) and roles (set of
  permissions)
- Permissions can now have inherited permissions (those act as roles)

RBAC DB structure is now limited to four tables
- rbac_permissions: Contains permissions and roles
- rbac_linked_permissions: Contains the relation between permissions and
  linked permissions (those permissions that have linked permissions are
  called roles)
- rbac_default_permissions: Contains the list of permissions to be granted
  to each security level [Added to maintain compatibility in an easy way]
- rbac_account_permissions: Contains the list of permissions granted or
  denied for a particular account.

NOTE: IF YOU ARE USING CUSTOM PERMISSIONS, ROLES OR GROUPS CHECK THE SQL
BEFORE APPLYING...
2013-09-29 13:19:05 +02:00
Spp 895a23df11 Core/RBAC: Add default groups to accounts based on their security level.
- Removed config option RBAC.DefaultGroups

Use the table rbac_security_level_groups to configure the groups to be added to the account at load time.

Note: Those groups are only used at run time, never saved to DB
2013-09-27 13:35:45 +02:00
Spp cfaea769bc Core/RBAC: Move RBAC code to namespace rbac 2013-09-27 13:35:45 +02:00
Jorge f0cd684cd1 Merge pull request #10800 from jackpoz/log_race_condition
Core/Logs: Fix race condition in Log
2013-09-13 12:22:31 -07:00
Spp 0ed83024e0 Core/RBAC: Fix typos in recent SQL files 2013-09-10 15:47:17 +02:00
Spp 953575abfa Core/RBAC: Remove obsolete generic command permissions
Note: If you have any custom command, CHECK THE SQLS BEFORE APPLYING
2013-09-10 15:35:10 +02:00
Spp 78363e11b5 Core/RBAC: Move titles and wp commands to RBAC (using individual permissions) 2013-09-10 15:26:48 +02:00
Spp b10241876e Core/RBAC: Move ticket commands to RBAC (using individual permissions) 2013-09-10 15:13:08 +02:00
Spp 68ab10ccd4 Core/RBAC: Move tele commands to RBAC (using individual permissions) 2013-09-10 15:01:39 +02:00
Spp abbc6b2760 Core/RBAC: Move server commands to RBAC (using individual permissions) 2013-09-10 14:57:01 +02:00
Spp 7183a355d2 Core/RBAC: Move reset commands to RBAC (using individual permissions) 2013-09-10 14:33:27 +02:00
Spp 1f95f0b0b8 Core/RBAC: Move reload command to RBAC (using individual permissions) 2013-09-10 14:25:07 +02:00
Spp 4f632ee3ff Core/RBAC: Move quest commands to RBAC (using individual permissions) 2013-09-10 13:57:30 +02:00
Spp efa194a7ce Core/RBAC: Move npc commands to RBAC (using individual permissions) 2013-09-10 13:48:57 +02:00
Spp 04b313557e Core/RBAC: Move modify commands to RBAC (using individual permissions) 2013-09-10 13:28:32 +02:00
Spp 4d36ce7405 Core/RBAC: Move mmap commands to RBAC (using individual permissions) 2013-09-10 13:08:39 +02:00
Spp 1038446278 Core/RBAC: Move misc commands to RBAC (using individual permissions) 2013-09-10 12:59:25 +02:00
Spp ec1e88d888 Core/RBAC: Move send commands to RBAC (using individual permissions) 2013-09-10 12:24:40 +02:00
Spp 83cb44d79f Core/RBAC: Move pet commands to RBAC (using individual permissions)
- Pet commands moved from cs_misc.cpp to own file
2013-09-10 12:07:03 +02:00
Spp 1eee42433b Core/RBAC: Move group commands to RBAC (using individual permissions)
- group commands moved from cs_misc.cpp to own file
- renamed groupsummon to "group summon"
2013-09-10 11:45:59 +02:00
Spp 0004d2e9cf Fix SQL typos after RBAC commits 2013-09-02 15:11:28 +02:00
Spp f3487aa0e1 Compile Fix (and edit of last 2 sqls to add the missing permissions) 2013-09-02 13:19:59 +02:00
Spp f68471f142 Core/RBAC: Move message commands to RBAC (using individual permissions) 2013-09-02 13:01:50 +02:00
Spp 2d508387e5 Core/Commands: Move lookup commands to RBAC (using individual permissions) 2013-09-02 12:54:51 +02:00
Spp eb73684952 Core/RBAC: Move list commands to RBAC (using individual permissions) 2013-09-02 12:25:32 +02:00
Spp 4219f45c85 Core/RBAC: Move lfg commands to RBAC (using individual permissions) 2013-09-02 12:17:46 +02:00
Spp c0dfdeab1c Core/RBAC: Move learn commands to RBAC (using individual permissions) 2013-09-02 12:12:20 +02:00
Spp 2625e78f80 Core/RBAC: Move instance commands to RBAC (using individual permissions) 2013-09-02 11:58:14 +02:00
Spp 08ef6bd9f8 Core/RBAC: Move honor commands to RBAC (using individual permissions) 2013-09-02 11:53:22 +02:00
Spp 11233dbd73 Core/RBAC: Move guild commands to RBAC (using individual permissions) 2013-09-02 11:45:36 +02:00
Spp 015eee068b Core/RBAC: Move gobject commands to RBAC (using individual permissions) 2013-09-02 11:38:41 +02:00
Spp 29c57c3447 Core/RBAC: Move go commands to RBAC (using individual permissions) 2013-09-02 11:33:45 +02:00
Spp 1bccf67c09 Core/RBAC: Move gm commands to RBAC (using individual permissions) 2013-09-02 11:24:09 +02:00
Spp fced8a896e Core/RBAC: Move event commands to RBAC (using individual permissions) 2013-09-02 11:20:05 +02:00
Spp 225691e0ae Core/RBAC: Move disable commands to RBAC (using individual permissions) 2013-09-02 11:17:15 +02:00
Spp cf9d01a0f3 Normalize sql file names from 722a6c1 2013-09-02 10:03:19 +02:00
Spp 3e45640135 Core/RBAC: Move deserter commands to RBAC (using individual permissions) 2013-09-02 10:01:34 +02:00
Spp f53c61c93e Core/RBAC: Move debug commands to RBAC (using individual permissions) 2013-09-02 10:01:34 +02:00
Spp 33d9da5060 Core/RBAC: Move cheat commands to RBAC (using individual permissions) 2013-09-02 10:01:34 +02:00
Spp 9bea4fc451 Core/RBAC: Move ban commands to RBAC (using individual permissions) 2013-08-30 16:26:52 +02:00
Spp 2b69f83823 Core/RBAC: Move Achievements and Arena commands to RBAC (using individual permissions) 2013-08-30 16:14:00 +02:00
Spp 109188a203 Core/RBAC: Move account commands to RBAC (using individual permissions) 2013-08-30 15:53:29 +02:00
Spp 17e8248070 Correct RBAC command names in DB 2013-08-30 15:23:47 +02:00
Spp e0d334bc81 Corrections to ea26928 sql files 2013-08-30 15:17:16 +02:00
Spp ea26928a99 Core/RBAC: Move RBAC commands to RBAC using individual permissions
- Use this commit as a sample on how to move commands to RBAC
2013-08-30 14:52:53 +02:00
Spp 3232b69ff3 Core/RBAC: Move commands security to RBAC (using generic RBAC Permissions)
- Warning: This will break commands for any custom security level
2013-08-30 13:57:09 +02:00
Spp 3e2e210890 Core/Build: Force minimum ACE (5.8.3) and OpenSSL (1.0.0) version detection
Core/Build: Do not ignore command line cmake options: ACE_INCLUDE_DIR, ACE_LIBRARY and OPENSSL_INCLUDE_DIR
2013-08-28 15:44:06 +02:00
Spp 33f8c3ead4 Core/Battleground: Get rid of dinamic casts BattlegroundXX outside Battleground scope by implementing generic functions (2/2)
- CheckAchievementCriteriaMeet
2013-08-07 11:13:53 +02:00
Spp b05665660a Core/Battleground: Get rid of dinamic casts BattlegroundXX outside Battleground scope by implementing generic functions (1/2)
- HandleQuestComplete, CanActivateGO and IsSpellAllowed
2013-08-07 10:31:13 +02:00
Spp f245124127 Core/Misc: Avoid heap allocation when performing some RBAC checks 2013-08-07 08:42:53 +02:00
Spp d58a037512 Build: Set _BUILD_DIRECTIVE even if the compiler is not properly detected 2013-06-27 10:47:30 +02:00
Spp a54244fb2d Fix compile 2013-06-12 14:16:51 +02:00
Spp 9664c0ab5c Core/Misc: Another batch of fixes for issues found by static analysis 2013-05-30 13:18:29 +02:00
Spp 782ea4309a Core/Misc: Fix invalid pointer use after being deleted 2013-05-30 13:18:29 +02:00
Spp 7ccbbdddd8 Core/Collision: Fix memory leak 2013-05-30 13:18:29 +02:00
Spp 00c1168897 Core/Misc: Remove trailing whitespace, compile warnings and minor cosmetic changes 2013-05-21 08:37:28 +02:00
Spp d3c2af0f66 Core/Build: Fix compile under Ubuntu 13.04 and openSUSE 12.3 (and probably other new distros)
Closes #9832
Closes #9740
2013-05-21 08:36:52 +02:00
Spp d1677b2db0 Core/Logging: Performance-related tweaks to logging system
All sLog->out* functions (except outCommand atm) are replaced with TC_LOG_* macros.
    Memleak fix
2013-05-13 15:07:36 +02:00
Spp 243c325ca4 Core: Declare some functions const and remove use of "using" directive in a couple of files 2013-05-13 15:04:05 +02:00
Spp d7d62e4248 Core: Fix compile with WITH_COREDEBUG option enabled 2013-03-26 19:34:49 +01:00
Spp 51287930cb Core/Build: All include directories are quoted to support path with spaces
Closes #9504
2013-03-26 13:45:47 +01:00
Spp 3c6c8c1117 Core/Misc: Remove the use of logging system from WPFatal (Fixes tools compile)
Closes #9501
2013-03-26 09:44:01 +01:00
Spp d03da1320a typo fix after 1a6a23e 2013-03-25 14:36:04 +01:00
Spp 1a6a23ec96 Core/Misc: Minor optimizations (+code changes to reduce differences with 4.3.4 branch)
Core/Logging: Create new logger type "Cheat". Will be used to log all cheat attempts
2013-03-25 13:26:48 +01:00
Spp 7c36e3a298 Core/Misc: Minor optimizations (+ code changes to reduce differences with 4.3.4 branch) 2013-03-25 10:36:30 +01:00
Spp 4429830ed7 Core: More functions moved to const 2013-03-21 15:13:51 +01:00
Spp 1496e4df84 Core/Pets: Remove unnecesary member variable (m_owner) 2013-03-21 15:00:43 +01:00
Spp 156fb824a4 Core/Scripts: Removed CAST_CRE define 2013-03-21 13:48:36 +01:00
Spp 355029fb4f Core/Scripts: Removed CAST_PLR define 2013-03-21 13:07:10 +01:00
Spp d091097433 Core/AI: Do not expose internal storage of SummonList 2013-03-21 11:06:05 +01:00
Spp 69e81d46b1 Core/Misc: Define multiple functions const (+ code cleanup here and there) 2013-03-20 14:20:17 +01:00
Spp af200bfaa5 Core/Account: Remove unused helper functions 2013-03-20 14:20:17 +01:00
Spp b4ee55dd05 Core/Misc: Do not use singleton when calling to static function ChooseDisplayId (and remove unused parameter) 2013-03-20 14:20:17 +01:00
Spp 44ea9cbb25 Core/RBAC: Fix players not being able to reply GMs from the other faction (Partial revert of 377cfdb) 2013-03-11 10:52:43 +01:00
Spp 524a10d628 Typo fix... ¬¬ 2013-03-08 14:05:51 +01:00
Spp 987826bc0d Core/RBAC: Change default db permissions to behave like a server with default config before RBAC conversion
(Missing change from previous commit)

To enable any of the removed config option you should now add the proper role to the proper groups
IE:
AllowTwoSide.Interaction.Mail = 1 --> Add role 19 to group 1 (Add it to players)
2013-03-08 13:58:15 +01:00
Spp 377cfdb560 Core/RBAC: Fix multiple permissions and remove multiple config options that are currently implementes by RBAC
- Remove config options: CONFIG_ALLOW_TWO_SIDE_INTERACTION_CHAT, CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL, CONFIG_GM_LOG_TRADE, CONFIG_ALLOW_TWO_SIDE_ACCOUNTS, CONFIG_ALLOW_TWO_SIDE_WHO_LIST, CONFIG_ALLOW_GM_FRIEND, CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND, CONFIG_SILENTLY_GM_JOIN_TO_CHANNEL
- Fix RBAC_PERM_SKIP_CHECK_CHAT_SPAM (Was checking spam for those that had the permission)
- Only check RBAC_PERM_TWO_SIDE_INTERACTION_CHAT for sender of whispers (Restores GM being able to whisper players)
- Only check RBAC_PERM_TWO_SIDE_INTERACTION_MAIL for sender
- Fix .ticket assign <Player>, with last RBAC change it was changed by mistake from Player to Account
2013-03-08 13:15:25 +01:00
Spp 480c6cf4dd Core/RBAC: Add .reload rbac command and prevent possible crash if rbac_permissions has wrong data 2013-02-27 03:30:53 +01:00
Spp 2a0c3a0b78 sql typo fixes 2013-02-26 23:20:52 +01:00
Spp 00c58f25d7 Core/RBAC: Force loadPermissions before checking session permissions if the storage is null (someone created a session but forgot to call to LoadPermissions) 2013-02-26 22:35:55 +01:00
Spp 2286de02f8 Core/RBAC: Correction to last sqls and update base/auth_database.sql 2013-02-26 15:25:46 +01:00
Spp ffdf54b082 Core/RBAC: Remove couple of harcoded checks for GM level and use Permission 'Log gm trade' 2013-02-25 15:59:16 +01:00
Spp d47b95cc0a Missing change related to permission 'Change channel settings' 2013-02-25 15:51:48 +01:00
Spp 0c2402df95 Core/RBAC: Create new permissions 'See two side who list', 'Add friends of other faction', 'See all levels with who command' and 'Allows to add a gm to friend list' 2013-02-25 15:48:19 +01:00
Spp fb9893a190 Add missing change related to permission 'Two side interaction channel' 2013-02-25 15:48:19 +01:00
Spp 019770dddb Core/RBAC: Create new permissions related to character creation
- 'Skips character creation team mask check'
- 'Skips character creation class mask check'
- 'Skips character creation race mask check'
- 'Skips character creation reserved name check'
- 'Skips character creation heroic min level check'
- 'Creation of two side faction characters in same account' (Affected by global config option)
2013-02-25 15:48:19 +01:00
Spp f67330e2ad Core/RBAC: Create new permissions 'Allow channel chat between factions', 'Join channels without announce' (both need config option enabled and permission set) and 'Change channel settings without being channel moderator' 2013-02-25 15:48:18 +01:00
Spp 18562a43ba Core/RBAC: Create new permissions 'Skips needed requirements to use channel check', 'Filter whispers', 'Allow say chat between factions'. Last one needs config option to be enabled and both sender and receiver to have the permission 2013-02-25 15:48:18 +01:00
Spp 9bd697066b Core/RBAC: Add new permissions 'Skip disable map check', 'Skip reset talents when used more than allowed check', 'Skip spam chat check', 'Restore saved gm setting states', 'Use Config option START_GM_LEVEL to assign new character level' 2013-02-25 15:48:18 +01:00
Spp fc78c48495 Core/RBAC: Create new permissions 'Notify if a command was not found' and 'Enables lower security than target check' 2013-02-25 15:48:18 +01:00
Spp d14cb26e6e Core/RBAC: Create new permission 'Two side mail interaction'. In order to send/receive mails from other faction, config option should be enabled and both sender and receiver should have the permission 2013-02-25 15:48:18 +01:00
Spp ea2e6052b2 Core/RBAC: Create new permissions 'Allow to use CMSG_WORLD_TELEPORT opcode' and 'Allow to use CMSG_WHOIS opcode' 2013-02-25 15:48:18 +01:00
Spp e99dd15915 Core/RBAC: Create new permission 'Skip over-speed ping check' 2013-02-25 15:48:18 +01:00
Spp 54f7cc326f Core/RBAC: Create new permission 'Receive global GM messages/texts' 2013-02-25 15:48:18 +01:00
Spp 367d3ccc4f Core/RBAC: Create new permissions 'Use staff badge in chat' and 'Check if should appear in .gm ingame command' 2013-02-25 15:48:18 +01:00