From: Lennart Poettering Date: Sat, 2 Dec 2017 11:48:31 +0000 (+0100) Subject: build-sys: make the dynamic UID range, and the container UID range configurable X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=a0d39da6b5b076931b9683a37d94b58a8011f966;p=elogind.git build-sys: make the dynamic UID range, and the container UID range configurable Also, export these ranges in our pkg-config files. --- diff --git a/src/basic/user-util.h b/src/basic/user-util.h index 4a1bc764a..f60166f79 100644 --- a/src/basic/user-util.h +++ b/src/basic/user-util.h @@ -67,13 +67,6 @@ int take_etc_passwd_lock(const char *root); #define UID_INVALID ((uid_t) -1) #define GID_INVALID ((gid_t) -1) -/* Let's pick a UIDs within the 16bit range, so that we are compatible with containers using 16bit - * user namespacing. At least on Fedora normal users are allocated until UID 60000, hence do not - * allocate from below this. Also stay away from the upper end of the range as that is often used - * for overflow/nobody users. */ -#define DYNAMIC_UID_MIN ((uid_t) UINT32_C(0x0000EF00)) -#define DYNAMIC_UID_MAX ((uid_t) UINT32_C(0x0000FFEF)) - static inline bool uid_is_dynamic(uid_t uid) { return DYNAMIC_UID_MIN <= uid && uid <= DYNAMIC_UID_MAX; }