[linux-pam] #4: [PATCH] po/ja.po: Fix some wrong translations and so on
by fedora-badges
#4: [PATCH] po/ja.po: Fix some wrong translations and so on
--------------------+-------------------------------------------------------
Reporter: fumiyas | Owner: pam-developers(a)lists.fedorahosted.org
Type: defect | Status: new
Priority: major | Component: library
Version: 1.1.x | Keywords: l10n
--------------------+-------------------------------------------------------
I've updated po/ja.po to fix some wrong translations and so on.
Please see and commit the attached patch to master repository if you feel
good.
Should I contact the original translator (Kiyoto Hashida
<khashida(a)redhat.com>) to check and confirm this patch?
--
Ticket URL: <https://fedorahosted.org/linux-pam/ticket/4>
linux-pam <http://fedorahosted.org/linux-pam>
The Linux-PAM (Pluggable Authentication Modules) project
8 years, 11 months
New Linux-PAM release?
by Thorsten Kukuk
Hi,
the last Linux-PAM release is now 1,5 year ago, since then we
made quite some code changes and the bug tracker looks pretty
good, means 3 enhancement requests and one defect are left.
So I would like to release a Linux-PAM 1.2.0 version during the
next days.
Any opinions?
Thorsten
--
Thorsten Kukuk, Senior Architect SLES & Common Code Base
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nuernberg, Germany
GF: Felix Imendörffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu, Graham Norton, HRB 21284 (AG Nürnberg)
9 years
[linux-pam] #29: pam_env documentation update
by fedora-badges
#29: pam_env documentation update
--------------------------+------------------------------
Reporter: kohtala | Owner: pam-developers@…
Type: enhancement | Status: new
Priority: major | Component: documentation
Version: 1.1.x | Keywords: pam_env
Blocked By: | Blocking:
--------------------------+------------------------------
I found pam_env and pam_env.conf documents very confusing and incomplete.
Once I figured out how it works, I wrote update.
--
Ticket URL: <https://fedorahosted.org/linux-pam/ticket/29>
linux-pam <http://fedorahosted.org/linux-pam>
The Linux-PAM (Pluggable Authentication Modules) project
9 years, 1 month
[linux-pam] #24: [PATCH] pam_env: Expand @{HOME} and @{SHELL}
by fedora-badges
#24: [PATCH] pam_env: Expand @{HOME} and @{SHELL}
--------------------------+------------------------------
Reporter: chrisse | Owner: pam-developers@…
Type: enhancement | Status: new
Priority: major | Component: modules
Version: | Keywords:
Blocked By: | Blocking:
--------------------------+------------------------------
I came across the problem of trying to modify XDG_DATA_HOME etc. to some
other value. pam_env seems to be the ideal point to set those variables,
and pam_env.conf supports expansions.
However, as already explained in the configuration examples, the ${HOME}
environment variable is only set later from the process calling PAM, so
there is currently no possibility to actually use this feature.
The following patch adds support to expand @{SHELL} and @{HOME}. It does
so by looking up the password database entry corresponding to the user and
returning the pw_dir and pw_shell fields.
The patch works, but it is not complete, since it does not update the
documentation. I consider it to be a proof of concept, since I didn't know
where exactly to fit in this functionality in the existing code.
--
Ticket URL: <https://fedorahosted.org/linux-pam/ticket/24>
linux-pam <http://fedorahosted.org/linux-pam>
The Linux-PAM (Pluggable Authentication Modules) project
9 years, 1 month
pam_env enhancement (Ticket#24)
by Thorsten Kukuk
Hi,
I used the patch from ticket#24 and enhanced it with documentation.
Ok to submit?
diff --git a/modules/pam_env/pam_env.c b/modules/pam_env/pam_env.c
index e04f5b5..1bfdf08 100644
--- a/modules/pam_env/pam_env.c
+++ b/modules/pam_env/pam_env.c
@@ -676,7 +676,7 @@ static const char * _pam_get_item_byname(pam_handle_t *pamh, const char *name)
const void *itemval;
D(("Called."));
- if (strcmp(name, "PAM_USER") == 0) {
+ if (strcmp(name, "PAM_USER") == 0 || strcmp(name, "HOME") == 0 || strcmp(name, "SHELL") == 0) {
item = PAM_USER;
} else if (strcmp(name, "PAM_USER_PROMPT") == 0) {
item = PAM_USER_PROMPT;
@@ -696,6 +696,19 @@ static const char * _pam_get_item_byname(pam_handle_t *pamh, const char *name)
D(("pam_get_item failed"));
return NULL; /* let pam_get_item() log the error */
}
+
+ if (itemval && (strcmp(name, "HOME") == 0 || strcmp(name, "SHELL") == 0)) {
+ struct passwd *user_entry;
+ user_entry = pam_modutil_getpwnam (pamh, (char *) itemval);
+ if (!user_entry) {
+ pam_syslog(pamh, LOG_ERR, "No such user!?");
+ return NULL;
+ }
+ return (strcmp(name, "SHELL") == 0) ?
+ user_entry->pw_shell :
+ user_entry->pw_dir;
+ }
+
D(("Exit."));
return itemval;
}
diff --git a/modules/pam_env/pam_env.conf.5.xml b/modules/pam_env/pam_env.conf.5.xml
index 45950b8..4040275 100644
--- a/modules/pam_env/pam_env.conf.5.xml
+++ b/modules/pam_env/pam_env.conf.5.xml
@@ -43,14 +43,16 @@
<para>
(Possibly non-existent) environment variables may be used in values
- using the ${string} syntax and (possibly non-existent) PAM_ITEMs may
- be used in values using the @{string} syntax. Both the $ and @
- characters can be backslash escaped to be used as literal values
+ using the ${string} syntax and (possibly non-existent) PAM_ITEMs as well
+ as HOME and SHELL may be used in values using the @{string} syntax. Both
+ the $ and @ characters can be backslash escaped to be used as literal values
values can be delimited with "", escaped " not supported.
Note that many environment variables that you would like to use
may not be set by the time the module is called.
- For example, HOME is used below several times, but
+ For example, ${HOME} is used below several times, but
many PAM applications don't make it available by the time you need it.
+ The special variables @{HOME} and @{SHELL} are expanded to the values
+ for the user from his <emphasis>passwd</emphasis> entry.
</para>
<para>
@@ -92,6 +94,7 @@
NNTPSERVER DEFAULT=localhost
PATH DEFAULT=${HOME}/bin:/usr/local/bin:/bin\
:/usr/bin:/usr/local/bin/X11:/usr/bin/X11
+ XDG_DATA_HOME @{HOME}/share/
</programlisting>
<para>
--
Thorsten Kukuk, Senior Architect SLES & Common Code Base
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nuernberg, Germany
GF: Felix Imendörffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu, Graham Norton, HRB 21284 (AG Nürnberg)
9 years, 1 month
Open tickets
by Thorsten Kukuk
Hi,
after cleaning up the ticket system and fixes the minor documentation
issues, we still have some open tickets:
#9 [PATCH] Allow pam_lastlog to write to utmp as an option
=> I suggest to reject that. That's more academic and not needed.
#20 compilation warnings
=> I suggest to ignore the last warnings
#24 [PATCH] pam_env: Expand @{HOME} and @{SHELL}
=> Any opinion about this? If you all think we should do it, I would look
at the patch.
#26 Use more fail safe method of indicating success from unix_chkpwd
=> Tomas, will you look at this?
#28 Allow module to put the tty to echo off mode via conversation function
=> Any volunteer for this one?
#29 pam_env documentation update
=> the patch in this form is unuseable, I think most docu is
harder to understand then currently. But some changes could
be usefull.
#30 Support for skipping to labels instead of numbers of rules.
=> I would suggest to reject this. Or any volunteer to implement this?
But I think this would not make the whole stuff better.
#34 support alternative "vendor configuration" files as fallback to /etc
=> This are two bugs in one
1. I disagree that modules should ignore that they are used but not
configured. This will only be confusing and a source for errors.
2. I don't like this /usr/lib/pam.d/ concept.
#37 Wrong SELinux AV used in pam_rootok?
=> Tomas, do you know more about this?
#39 [PATCH] doc: pam_access docs are incomplete/misleading
=> the patch looks Ok for me.
#40 expose_auth doesnt work with pam_exec when user does not exist
=> I don't understand why this should not work by looking at the code.
Looks more like a stacking issue, need to dig deeper into this.
Your comments?
Thorsten
--
Thorsten Kukuk, Senior Architect SLES & Common Code Base
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nuernberg, Germany
GF: Felix Imendörffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu, Graham Norton, HRB 21284 (AG Nürnberg)
9 years, 1 month
[linux-pam] #39: pam_access docs are incomplete/misleading
by fedora-badges
#39: pam_access docs are incomplete/misleading
---------------------+------------------------------
Reporter: kop | Owner: pam-developers@…
Type: defect | Status: new
Priority: minor | Component: documentation
Version: | Keywords: pam_access
Blocked By: | Blocking:
---------------------+------------------------------
The pam_access docs are incomplete regarding how daemons
and X sessions are handled. (LOCAL access that
does not have an associated tty.) This makes the
example regarding X sessions confusing and appear
to contain more "fields" than the documentation allows.
The attached patch clarifies the docs.
Note that the patch was submitted to
pam-developers(a)lists.fedorahosted.org.
Date: 2014-09-01
https://lists.fedorahosted.org/pipermail/pam-
developers/2014-September/000652.html
See also:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762110
The following text describes the license under which this patch is
submitted (since fedorahosted seems to want licenseing information with a
patch):
-------------------------------------------------------------------------
Redistribution and use in source and binary forms of Linux-PAM, with
or without modification, are permitted provided that the following
conditions are met:
1. Redistributions of source code must retain any existing copyright
notice, and this entire permission notice in its entirety,
including the disclaimer of warranties.
2. Redistributions in binary form must reproduce all prior and current
copyright notices, this list of conditions, and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
3. The name of any author may not be used to endorse or promote
products derived from this software without their specific prior
written permission.
ALTERNATIVELY, this product may be distributed under the terms of the
GNU General Public License, in which case the provisions of the GNU
GPL are required INSTEAD OF the above restrictions. (This clause is
necessary due to a potential conflict between the GNU GPL and the
restrictions contained in a BSD-style copyright.)
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
DAMAGE.
-------------------------------------------------------------------------
--
Ticket URL: <https://fedorahosted.org/linux-pam/ticket/39>
linux-pam <http://fedorahosted.org/linux-pam>
The Linux-PAM (Pluggable Authentication Modules) project
9 years, 1 month
[linux-pam] #20: compilation warnings
by fedora-badges
#20: compilation warnings
---------------------+------------------------------
Reporter: mirraz | Owner: pam-developers@…
Type: defect | Status: new
Priority: minor | Component: library
Version: | Keywords:
Blocked By: | Blocking:
---------------------+------------------------------
Building pam-1.1.6 I'v got this compilation warnings:
{{{
md5.c:145:2: warning: dereferencing type-punned pointer will break strict-
aliasing rules [-Wstrict-aliasing]
md5.c:146:2: warning: dereferencing type-punned pointer will break strict-
aliasing rules [-Wstrict-aliasing]
misc_conv.c:213:22: warning: the address of ‘line’ will always evaluate as
‘true’ [-Waddress]
misc_conv.c:325:15: warning: the address of ‘binary_prompt’ will always
evaluate as ‘true’ [-Waddress]
}}}
--
Ticket URL: <https://fedorahosted.org/linux-pam/ticket/20>
linux-pam <http://fedorahosted.org/linux-pam>
The Linux-PAM (Pluggable Authentication Modules) project
9 years, 1 month