Skip to content
Commits on Source (30)
......@@ -326,6 +326,7 @@ pkgconfigdir = $(libdir)/pkgconfig
serverincdir = $(includedir)/@serverincdir@
gdbautoloaddir = $(prefixdir)/share/gdb/auto-load$(sbindir)
cockpitdir = $(prefixdir)/share/cockpit@cockpitdir@
metainfodir = $(prefixdir)/share/metainfo/389-console
# This has to be hardcoded to /lib - $libdir changes between lib/lib64, but
# sysctl.d is always in /lib.
......@@ -647,7 +648,6 @@ dist_noinst_DATA = \
$(srcdir)/LICENSE \
$(srcdir)/LICENSE.* \
$(srcdir)/VERSION.sh \
$(srcdir)/setup.py.in \
$(srcdir)/wrappers/*.in \
$(srcdir)/wrappers/systemd.template.sysconfig \
$(srcdir)/dirsrvtests \
......@@ -758,8 +758,11 @@ libexec_SCRIPTS = ldap/admin/src/scripts/ds_selinux_enabled \
install-data-hook:
if [ "$(srcdir)" != "." ]; then cp -r $(srcdir)/src/cockpit src ; fi
mkdir -p src/cockpit/389-console/cockpit_dist/
mkdir -p $(DESTDIR)$(cockpitdir)
rsync -rupE src/cockpit/389-console/ $(DESTDIR)$(cockpitdir)
rsync -rupE src/cockpit/389-console/cockpit_dist/ $(DESTDIR)$(cockpitdir)
mkdir -p $(DESTDIR)$(metainfodir)
rsync -up src/cockpit/389-console/org.cockpit-project.389-console.metainfo.xml $(DESTDIR)$(metainfodir)/org.cockpit-project.389-console.metainfo.xml
if ENABLE_PERL
sbin_SCRIPTS = ldap/admin/src/scripts/setup-ds.pl \
......@@ -2379,11 +2382,28 @@ lib389: src/lib389/setup.py
lib389-install: lib389
cd $(srcdir)/src/lib389; $(PYTHON) setup.py install --skip-build --force
tests: setup.py.in lib389
$(PYTHON) setup.py build
NODE_MODULES_TEST = src/cockpit/389-console/node_modules/webpack
WEBPACK_TEST = src/cockpit/389-console/cockpit_dist/index.html
tests-install: tests
$(PYTHON) setup.py install
# Cockpit UI plugin - we install the dependancies and build the JS sources
# and then we use install-data-hook for copying the results on 'make install'
$(NODE_MODULES_TEST):
cd src/cockpit/389-console; make -f node_modules.mk install
$(WEBPACK_TEST): $(NODE_MODULES_TEST)
cd src/cockpit/389-console; make -f node_modules.mk build-cockpit-plugin
389-console: $(WEBPACK_TEST)
# This requires a built source tree and avoids having to install anything system-wide
389-console-devel-install:
cd $(srcdir)/src/cockpit/389-console; \
rm ~/.local/share/cockpit/389-console; \
mkdir -p ~/.local/share/cockpit/; \
ln -s $$(pwd)/dist ~/.local/share/cockpit/389-console
389-console-clean:
cd $(srcdir)/src/cockpit/389-console; make -f node_modules.mk clean
# RPM-related tasks
......
......@@ -10,7 +10,7 @@ vendor="389 Project"
# PACKAGE_VERSION is constructed from these
VERSION_MAJOR=1
VERSION_MINOR=4
VERSION_MAINT=0.18
VERSION_MAINT=0.19
# NOTE: VERSION_PREREL is automatically set for builds made out of a git tree
VERSION_PREREL=
VERSION_DATE=$(date -u +%Y%m%d)
......
#!/usr/bin/python
#!/usr/bin/python3
#
# --- BEGIN COPYRIGHT BLOCK ---
# Copyright (C) 2016 Red Hat, Inc.
......@@ -122,8 +122,9 @@ def check_id_uniqueness(id_value):
for root, dirs, files in os.walk(tests_dir):
for name in files:
with open(os.path.join(root, name), "r") as file:
for line in file:
if name.endswith('.py'):
with open(os.path.join(root, name), "r") as cifile:
for line in cifile:
if re.search(str(id_value), line):
return False
......
"""
:Requirement: 389-ds-base: Access Control Instructions (ACI)
"""
"""
:Requirement: 389-ds-base: Auto Member
"""
"""
:Requirement: 389-ds-base: Basic Directory Server Operations
"""
......@@ -1088,6 +1088,57 @@ def test_critical_msg_on_empty_range_idl(topology_st):
# Step 5
assert not topology_st.standalone.searchErrorsLog('CRIT - list_candidates - NULL idl was recieved from filter_candidates_ext.')
def audit_pattern_found(server, log_pattern):
file_obj = open(server.ds_paths.audit_log, "r")
found = None
# Use a while true iteration because 'for line in file: hit a
log.info('Audit log contains')
while True:
line = file_obj.readline()
log.info(line)
found = log_pattern.search(line)
if ((line == '') or (found)):
break
return found
@pytest.mark.ds50026
def test_ticketldbm_audit(topology_st):
"""When updating LDBM config attributes, those attributes/values are not listed
in the audit log
:id: 5bf75c47-a283-430e-a65c-3c5fd8dbadb8
:setup: Standalone Instance
:steps:
1. Enable audit log
2. Update a set of config attrs in LDBM config
3. Disable audit log (to restore the default config)
4. Check that config attrs are listed in the audit log
:expectedresults:
1. Should succeeds
2. Should succeeds
3. Should succeeds
4. Should succeeds
"""
inst = topology_st[0]
inst.config.enable_log('audit')
#inst.ds_paths.audit_log
attrs = ['nsslapd-lookthroughlimit', 'nsslapd-pagedidlistscanlimit', 'nsslapd-idlistscanlimit', 'nsslapd-db-locks']
mods = []
for attr in attrs:
mods.append((ldap.MOD_REPLACE, attr, b'10001'))
inst.modify_s(DN_CONFIG_LDBM, mods)
inst.config.enable_log('audit')
for attr in attrs:
log.info("Check %s is replaced in the audit log" % attr)
regex = re.compile("^replace: %s" % attr)
assert audit_pattern_found(inst, regex)
if __name__ == '__main__':
# Run isolated
# -s for DEBUG mode
......
"""
:Requirement: 389-ds-base: betxn Plugin
"""
"""
:Requirement: 389-ds-base: Command Line Utility
"""
"""
:Requirement: 389-ds-base: Directory Server Configurations
"""
"""
:Requirement: 389-ds-base: Class of Service
"""
"""
:Requirement: 389-ds-base: Directory Server Logs
"""
"""
:Requirement: 389-ds-base: Directory Server Tools
"""
"""
:Requirement: 389-ds-base: LDAP Filters
"""
"""
:Requirement: 389-ds-base: Get Effective Rights
"""
"""
:Requirement: 389-ds-base: GSSAPI Authentication
"""
"""
:Requirement: 389-ds-base: GSSAPI Authentication Replication
"""
"""
:Requirement: 389-ds-base: DataBase Import
"""