[WIKI] Contribute and DevelTips are duplicate
by Petr Cech
Hi,
I've read the wiki according to
# https://fedorahosted.org/sssd/ticket/2706
and I think that it could be helpful clean the page
# https://fedorahosted.org/sssd/wiki/DevelTutorials
from "git topic" and create new page for everything related to git.
The motivation is, that:
* Contribute briefly describe whole process on basic level,
* DevelTips looks like How To,
* DevelTutorials are more about technologies, libraries, build process...,
* So there could be one page for everything about git.
--------------------------------------------------------------------------------
NOTES how we could edit wiki:
--------------------------------------------------------------------------------
https://fedorahosted.org/sssd/wiki/Contribute
Contribute
Contribution Policy
Source Code Repository /*
* There could be only a link to the
repo and
* reference to "New Git page".
*/
Tips and tricks for developers
QA, Development and Bug Triage
Development Repositories
Localization and Internationalization
Design Pages
Credits
Latest Documentation and Presentations
https://fedorahosted.org/sssd/wiki/DevelTips
SSSD Devel page
Are there any introductory tutorials available?
/* + Reference to the new "Git page" */
When I debug an SSSD process in a debugger, it always gets
killed with …
Using valgrind to identify memory access problems
Using strace to track the SSSD processes
How do I track work-in-progress of other developers? /*
* Is it
* still valid?
*
* I tried link
* for jhrozek and
* his sssd.git
* and the url
* doesn't exist.
*/
Why does make check take so long?
Using clang to perform static analysis of source code
When I compile the SSSD from source there is an error that says …
https://fedorahosted.org/sssd/wiki/DevelTutorials
/*
* Label @new-git-page means
* that I would like move given paragraph to the "New git page"
*/
Talloc
Tevent and tevent_req
Coding Style
Code Contributions /* @new-git-page */
Getting the source /* @new-git-page */
Building SSSD for development and debugging
Unit tests
Submitting a patch upstream /* @new-git-page */
Patch metadata /* @new-git-page */
Translation Contributions
Devel Tips
"New Git page" /* Maybe Git Tips? */
+ paragraph about git setup from Contribute->Source Code Repository
+ some paragraphs of DevelTutorials->Code Contributions
--------------------------------------------------------------------------------
I am looking forward your opinions.
Petr
8 years, 5 months
[PATCH] UTIL: Alternative way for debug message initialisation
by Lukas Slebodnik
ehlo,
attached patch shoul avoid situation as in commit 7c69221077c780e62f6c536e78675f2dc1c131bc
The comments does not guarantee anything.
Author: Michal Zidek <mzidek(a)redhat.com>
Date: Tue Mar 10 17:30:48 2015 +0100
DEBUG: Add missing strings for error messages
We had more error codes than corresponding
messages. Also order of two messages was wrong.
Unfortunatelly, the index of enum do not start from 0
and need to be converted using SSSD_ERR_IDX. I used shorter version of
macro "idx". Feel free to propose nicer name.
LS
8 years, 5 months
[PATCH] [HBAC]: Better libhbac debuging
by Petr Cech
Hi,
according to
https://fedorahosted.org/sssd/ticket/2703
I tried to add logging to the library HBAC.
A)
Logging is performed using an external function, which you can set by:
# hbac_enable_debug(...)
B)
The specific implementation of such a function, you can see
# hbac_debug_messages(...)
C)
You can specify debug level:
'...' stands for
sssd_cygnus.dev.log:(Fri Jul 24 10:29:36 2015) [sssd[be[cygnus.dev]]]
[hbac] (0x0080): [../src/providers/ipa/
* SSSDBG_MINOR_FAILURE produces:
Question: What kind of information could I add for request into this level?
...hbac_evaluator.c:150] [< hbac_evaluate()
...hbac_evaluator.c:173] DISALLOWED by rule [szabo_allowed].
...hbac_evaluator.c:180] ALLOWED by rule [Test_rule].
...hbac_evaluator.c:214] hbac_evaluate() >]
...hbac_evaluator.c:150] [< hbac_evaluate()
...hbac_evaluator.c:173] DISALLOWED by rule [szabo_allowed].
...hbac_evaluator.c:173] DISALLOWED by rule [Test_rule].
...hbac_evaluator.c:214] hbac_evaluate() >]
...hbac_evaluator.c:150] [< hbac_evaluate()
...hbac_evaluator.c:173] DISALLOWED by rule [szabo_allowed].
...hbac_evaluator.c:173] DISALLOWED by rule [Test_rule].
...hbac_evaluator.c:214] hbac_evaluate() >]
* SSSDBG_TRACE_ALL produces:
...hbac_evaluator.c:150] [< hbac_evaluate()
...hbac_evaluator.c:410] REQUEST:
...hbac_evaluator.c:391] service [sshd]
...hbac_evaluator.c:400] service_group (none)
...hbac_evaluator.c:391] user [csikos]
...hbac_evaluator.c:395] user_group:
...hbac_evaluator.c:397] [ipausers]
...hbac_evaluator.c:391] targethost [albireo.cygnus.dev]
...hbac_evaluator.c:400] targethost_group (none)
...hbac_evaluator.c:391] srchost [192.168.122.106]
...hbac_evaluator.c:400] srchost_group (none)
...hbac_evaluator.c:417] request time Fri Jul 24 14:29:36 2015
...hbac_evaluator.c:454] RULE [szabo_allowed] [ENABLED]:
...hbac_evaluator.c:456] services:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:435] services_names (none)
...hbac_evaluator.c:440] services_groups:
...hbac_evaluator.c:442] [Sudo]
...hbac_evaluator.c:462] users:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:435] users_names (none)
...hbac_evaluator.c:445] users_groups (none)
...hbac_evaluator.c:468] targethosts:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] targethosts_names:
...hbac_evaluator.c:432] [albireo.cygnus.dev]
...hbac_evaluator.c:445] targethosts_groups (none)
...hbac_evaluator.c:474] srchosts:
...hbac_evaluator.c:427] category [0x1] [ALL]
...hbac_evaluator.c:173] DISALLOWED by rule [szabo_allowed].
...hbac_evaluator.c:454] RULE [Test_rule] [ENABLED]:
...hbac_evaluator.c:456] services:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] services_names:
...hbac_evaluator.c:432] [login]
...hbac_evaluator.c:432] [sshd]
...hbac_evaluator.c:432] [su]
...hbac_evaluator.c:445] services_groups (none)
...hbac_evaluator.c:462] users:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] users_names:
...hbac_evaluator.c:432] [csikos]
...hbac_evaluator.c:445] users_groups (none)
...hbac_evaluator.c:468] targethosts:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] targethosts_names:
...hbac_evaluator.c:432] [albireo.cygnus.dev]
...hbac_evaluator.c:445] targethosts_groups (none)
...hbac_evaluator.c:474] srchosts:
...hbac_evaluator.c:427] category [0x1] [ALL]
...hbac_evaluator.c:180] ALLOWED by rule [Test_rule].
...hbac_evaluator.c:214] hbac_evaluate() >]
...hbac_evaluator.c:150] [< hbac_evaluate()
...hbac_evaluator.c:410] REQUEST:
...hbac_evaluator.c:391] service [systemd-user]
...hbac_evaluator.c:400] service_group (none)
...hbac_evaluator.c:391] user [csikos]
...hbac_evaluator.c:395] user_group:
...hbac_evaluator.c:397] [ipausers]
...hbac_evaluator.c:391] targethost [albireo.cygnus.dev]
...hbac_evaluator.c:400] targethost_group (none)
...hbac_evaluator.c:400] srchost_group (none)
...hbac_evaluator.c:417] request time Fri Jul 24 14:29:36 2015
...hbac_evaluator.c:454] RULE [szabo_allowed] [ENABLED]:
...hbac_evaluator.c:456] services:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:435] services_names (none)
...hbac_evaluator.c:440] services_groups:
...hbac_evaluator.c:442] [Sudo]
...hbac_evaluator.c:462] users:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:435] users_names (none)
...hbac_evaluator.c:445] users_groups (none)
...hbac_evaluator.c:468] targethosts:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] targethosts_names:
...hbac_evaluator.c:432] [albireo.cygnus.dev]
...hbac_evaluator.c:445] targethosts_groups (none)
...hbac_evaluator.c:474] srchosts:
...hbac_evaluator.c:427] category [0x1] [ALL]
...hbac_evaluator.c:173] DISALLOWED by rule [szabo_allowed].
...hbac_evaluator.c:454] RULE [Test_rule] [ENABLED]:
...hbac_evaluator.c:456] services:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] services_names:
...hbac_evaluator.c:432] [login]
...hbac_evaluator.c:432] [sshd]
...hbac_evaluator.c:432] [su]
...hbac_evaluator.c:445] services_groups (none)
...hbac_evaluator.c:462] users:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] users_names:
...hbac_evaluator.c:432] [csikos]
...hbac_evaluator.c:445] users_groups (none)
...hbac_evaluator.c:468] targethosts:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] targethosts_names:
...hbac_evaluator.c:432] [albireo.cygnus.dev]
...hbac_evaluator.c:445] targethosts_groups (none)
...hbac_evaluator.c:474] srchosts:
...hbac_evaluator.c:427] category [0x1] [ALL]
...hbac_evaluator.c:173] DISALLOWED by rule [Test_rule].
...hbac_evaluator.c:214] hbac_evaluate() >]
...hbac_evaluator.c:150] [< hbac_evaluate()
...hbac_evaluator.c:410] REQUEST:
...hbac_evaluator.c:391] service [sshd]
...hbac_evaluator.c:400] service_group (none)
...hbac_evaluator.c:391] user [szabo]
...hbac_evaluator.c:395] user_group:
...hbac_evaluator.c:397] [ipausers]
...hbac_evaluator.c:391] targethost [albireo.cygnus.dev]
...hbac_evaluator.c:400] targethost_group (none)
...hbac_evaluator.c:391] srchost [192.168.122.106]
...hbac_evaluator.c:400] srchost_group (none)
...hbac_evaluator.c:417] request time Fri Jul 24 14:29:46 2015
...hbac_evaluator.c:454] RULE [szabo_allowed] [ENABLED]:
...hbac_evaluator.c:456] services:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:435] services_names (none)
...hbac_evaluator.c:440] services_groups:
...hbac_evaluator.c:442] [Sudo]
...hbac_evaluator.c:462] users:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] users_names:
...hbac_evaluator.c:432] [szabo]
...hbac_evaluator.c:445] users_groups (none)
...hbac_evaluator.c:468] targethosts:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] targethosts_names:
...hbac_evaluator.c:432] [albireo.cygnus.dev]
...hbac_evaluator.c:445] targethosts_groups (none)
...hbac_evaluator.c:474] srchosts:
...hbac_evaluator.c:427] category [0x1] [ALL]
...hbac_evaluator.c:173] DISALLOWED by rule [szabo_allowed].
...hbac_evaluator.c:454] RULE [Test_rule] [ENABLED]:
...hbac_evaluator.c:456] services:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] services_names:
...hbac_evaluator.c:432] [login]
...hbac_evaluator.c:432] [sshd]
...hbac_evaluator.c:432] [su]
...hbac_evaluator.c:445] services_groups (none)
...hbac_evaluator.c:462] users:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] users_names:
...hbac_evaluator.c:432] [csikos]
...hbac_evaluator.c:445] users_groups (none)
...hbac_evaluator.c:468] targethosts:
...hbac_evaluator.c:427] category [0] [NONE]
...hbac_evaluator.c:430] targethosts_names:
...hbac_evaluator.c:432] [albireo.cygnus.dev]
...hbac_evaluator.c:445] targethosts_groups (none)
...hbac_evaluator.c:474] srchosts:
...hbac_evaluator.c:427] category [0x1] [ALL]
...hbac_evaluator.c:173] DISALLOWED by rule [Test_rule].
...hbac_evaluator.c:214] hbac_evaluate() >]
Thanks.
Petr
8 years, 6 months
RFC: Improving the debug messages
by Jakub Hrozek
Hi,
I spent many hours debugging SSSD in different scenarios last week and I
admit it wasn't always easy -- and I have the source code knowledge I
can use. I imagine it's considerably harder for users and admins..
So this is a brainstorm request on how can we make debugging with SSSD
easier. Maybe there are some low-hanging fruits that can be fixed
easily. Off the top of my head:
- it should be easier to see start and end of a request in the back end.
Instead of:
[be_get_account_info] (0x0200): Got request for [0x1001][1][name=admin]
[acctinfo_callback] (0x0100): Request processed. Returned 0,0,Success (Success)
We could make the debug messages more explicit:
[be_get_account_info] (0x0200): Received request for [object=user][key=name][value=admin]
[acctinfo_callback] (0x0200): Finished request for [object=user][key=name][value=admin]. Returned 0,0,Success
Then we could document the messages in our troubleshooting document.
Please note I'm not proposing to turn debug messages into any kind of
API and keep them the same forever, but decorate the usual flow with
messages that make sense without source level knowledge.
- same for authentication
- same for responder cache requests. We seem to have gotten better with
the new cache_req code there, so this is mostly about using the new
code in all responders. But also the commands we receive from sockets
should be printed in human-readable form.
- Running sssd in environment where all actions complete successfully
should emit no debug messages. Default log level should be moved to
SSSDBG_OP_FAILURE or CRIT_FAILURE. (This basically amounts to checking
all OP, FATAL and CRIT failure messages..)
The reason is that sometimes sssd fails, but because logging is
totally silent, we don't know what happened at all. Currently we have
a couple of small bugs where we might print a loud DEBUG message just
because we search for an entry which is not there etc.
- anything that causes SSSD to fail to start should also emit a syslog
message. Admins don't really know about sssd debug logs.
- our man pages are not structured well, especially the LDAP man page is
too big and contains too many options.
One reason I'm bringing this up now is that we'll have a new SSSD developer
starting soon and these might be nice tasks to start with AND they're
also needed.
8 years, 6 months
[PATCH] [sssd-1.11] pysss_nss_idmap: Use wrapper for older python
by Lukas Slebodnik
ehlo,
we dropped support for old version of python (<2.6)
in recent version of sssd. It should work in 1.11 branch
but there was a small issue in pysss_nss_idmap bindings.
Attached is a simple patch wich reuse our internal python wrappers.
LS
8 years, 6 months