Changeset 862 in openpam for trunk/lib


Ignore:
Timestamp:
Jul 30, 2015, 11:42:38 PM (5 years ago)
Author:
Dag-Erling Smørgrav
Message:

Add a feature flag to control whether to fall back to the "other" policy
for chains that are still empty after the requested policy was loaded.

Location:
trunk/lib/libpam
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/libpam/openpam_configure.c

    r795 r862  
    468468                if (pamh->chains[fclt] != NULL)
    469469                        continue;
    470                 if (openpam_load_chain(pamh, PAM_OTHER, fclt) < 0)
    471                         goto load_err;
     470                if (OPENPAM_FEATURE(FALLBACK_TO_OTHER)) {
     471                        if (openpam_load_chain(pamh, PAM_OTHER, fclt) < 0)
     472                                goto load_err;
     473                }
    472474        }
    473475        RETURNC(PAM_SUCCESS);
  • trunk/lib/libpam/openpam_features.c

    r648 r862  
    6666            1
    6767        ),
     68        STRUCT_OPENPAM_FEATURE(
     69            FALLBACK_TO_OTHER,
     70            "Fall back to \"other\" policy for empty chains",
     71            1
     72        ),
    6873};
Note: See TracChangeset for help on using the changeset viewer.