File: 045_pam_dispatch_jump_is_ignore

package info (click to toggle)
pam 1.1.8-3.6
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 11,800 kB
  • ctags: 2,930
  • sloc: ansic: 31,350; xml: 21,611; sh: 11,344; makefile: 1,563; perl: 893; yacc: 408; lex: 70; sed: 16
file content (31 lines) | stat: -rw-r--r-- 1,111 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31

Previously jumps were treated as PAM_IGNORE in the freezing part of
the chain and PAM_OK (aka required) in the frozen part of the chain.
No one on pam-list was able to explain this behavior, so I changed it
to be consistent.

Index: pam.debian/libpam/pam_dispatch.c
===================================================================
--- pam.debian.orig/libpam/pam_dispatch.c
+++ pam.debian/libpam/pam_dispatch.c
@@ -254,19 +254,7 @@
 	    if ( _PAM_ACTION_IS_JUMP(action) ) {
 
 		/* If we are evaluating a cached chain, we treat this
-		   module as required (aka _PAM_ACTION_OK) as well as
-		   executing the jump. */
-
-		if (use_cached_chain) {
-		    if (impression == _PAM_UNDEF
-			|| (impression == _PAM_POSITIVE
-			    && status == PAM_SUCCESS) ) {
-			if ( retval != PAM_IGNORE || cached_retval == retval ) {
-			    impression = _PAM_POSITIVE;
-			    status = retval;
-			}
-		    }
-		}
+		   module as ignored as well as executing the jump. */
 
 		/* this means that we need to skip #action stacked modules */
 		while (h->next != NULL && h->next->stack_level >= stack_level && action > 0) {