Compare commits

...

No commits in common. "c10s" and "c8-stream-10.6" have entirely different histories.

15 changed files with 91 additions and 282 deletions

21
.gitignore vendored
View File

@ -1,20 +1 @@
ldapjdk-4.18.tar.gz SOURCES/ldap-sdk-4.24.0.tar.gz
/ldapjdk-4.19.tar.gz
/ldap-sdk-4.20.0.tar.gz
/ldap-sdk-4.21.0.tar.gz
/ldap-sdk-4.22.0.tar.gz
/ldap-sdk-4.23.0-alpha1.tar.gz
/ldap-sdk-5.0.0-alpha1.tar.gz
/ldap-sdk-5.0.0-alpha2.tar.gz
/ldap-sdk-5.0.0.tar.gz
/ldap-sdk-5.1.0.tar.gz
/ldap-sdk-5.2.0-beta1.tar.gz
/ldap-sdk-5.2.0-beta2.tar.gz
/ldap-sdk-5.2.0.tar.gz
/ldap-sdk-5.3.0-beta1.tar.gz
/ldap-sdk-5.3.0.tar.gz
/ldap-sdk-5.4.0.tar.gz
/ldap-sdk-5.4.1.tar.gz
/ldap-sdk-5.5.0-alpha4.tar.gz
/ldap-sdk-5.5.0.tar.gz
/ldap-sdk-5.6.0-alpha1.tar.gz

1
.ldapjdk.metadata Normal file
View File

@ -0,0 +1 @@
5ae502d4aec13f94d581384faedf2fa67d87cffa SOURCES/ldap-sdk-4.24.0.tar.gz

View File

@ -1,30 +0,0 @@
---
# See the documentation for more information:
# https://packit.dev/docs/configuration/
specfile_path: ldapjdk.spec
# add or remove files that should be synced
files_to_sync:
- ldapjdk.spec
- .packit.yaml
# Allow dist git reactions on packit and ckelley commits and PRs
allowed_pr_authors:
- packit
- ckelleyRH
allowed_committers:
- packit
- ckelleyRH
upstream_package_name: ldap-sdk
# downstream (Fedora/CentOS) RPM package name
downstream_package_name: ldapjdk
# see: https://packit.dev/docs/configuration/#upstream_tag_template
upstream_tag_template: "v{version}"
jobs:
- job: propose_downstream
trigger: release
dist_git_branches:
- fedora-development
# - centos-stream-9-x86_64 # When Packit integration with CentOS is avaiable, enable this

View File

@ -1,3 +0,0 @@
This repository is maintained by packit.
https://packit.dev/
The file was generated using packit 0.76.0.post10+g0dcb396.

View File

@ -2,33 +2,29 @@
Name: ldapjdk Name: ldapjdk
################################################################################ ################################################################################
%global vendor_id idm %global product_id idm-ldapjdk
%global product_id %{vendor_id}-ldapjdk
# Upstream version number: # Upstream version number:
%global major_version 5 %global major_version 4
%global minor_version 6 %global minor_version 24
%global update_version 0 %global update_version 0
# Downstream release number:
# - development/stabilization (unsupported): 0.<n> where n >= 1
# - GA/update (supported): <n> where n >= 1
%global release_number 0.1
# Development phase:
# - development (unsupported): alpha<n> where n >= 1
# - stabilization (unsupported): beta<n> where n >= 1
# - GA/update (supported): <none>
%global phase alpha1
%undefine timestamp
%undefine commit_id
Summary: LDAP SDK Summary: LDAP SDK
URL: https://github.com/dogtagpki/ldap-sdk URL: https://github.com/dogtagpki/ldap-sdk
License: MPL-1.1 OR GPL-2.0-or-later OR LGPL-2.1-or-later License: MPLv1.1 or GPLv2+ or LGPLv2+
BuildArch: noarch
# For development (i.e. unsupported) releases, use x.y.z-0.n.<phase>.
# For official (i.e. supported) releases, use x.y.z-r where r >=1.
%global release_number 1
Version: %{major_version}.%{minor_version}.%{update_version} Version: %{major_version}.%{minor_version}.%{update_version}
Release: %{release_number}%{?phase:.}%{?phase}%{?timestamp:.}%{?timestamp}%{?commit_id:.}%{?commit_id}%{?dist} Release: %{release_number}%{?_timestamp}%{?_commit_id}%{?dist}
#global _phase -alpha1
%global spname ldapsp
%global filtname ldapfilt
%global beansname ldapbeans
# To create a tarball from a version tag: # To create a tarball from a version tag:
# $ git archive \ # $ git archive \
@ -36,7 +32,7 @@ Release: %{release_number}%{?phase:.}%{?phase}%{?timestamp:.}%{?timesta
# --prefix ldap-sdk-<version>/ \ # --prefix ldap-sdk-<version>/ \
# -o ldap-sdk-<version>.tar.gz \ # -o ldap-sdk-<version>.tar.gz \
# <version tag> # <version tag>
Source: https://github.com/dogtagpki/ldap-sdk/archive/v%{version}%{?phase:-}%{?phase}/ldap-sdk-%{version}%{?phase:-}%{?phase}.tar.gz Source: https://github.com/dogtagpki/ldap-sdk/archive/v%{version}%{?_phase}/ldap-sdk-%{version}%{?_phase}.tar.gz
# To create a patch for all changes since a version tag: # To create a patch for all changes since a version tag:
# $ git format-patch \ # $ git format-patch \
@ -45,18 +41,19 @@ Source: https://github.com/dogtagpki/ldap-sdk/archive/v%{version}%{?phase:-}%{?p
# > ldap-sdk-VERSION-RELEASE.patch # > ldap-sdk-VERSION-RELEASE.patch
# Patch: ldap-sdk-VERSION-RELEASE.patch # Patch: ldap-sdk-VERSION-RELEASE.patch
BuildArch: noarch
%if 0%{?java_arches:1}
ExclusiveArch: %{java_arches} noarch
%endif
################################################################################ ################################################################################
# Java # Java
################################################################################ ################################################################################
%define java_devel java-21-openjdk-devel %if 0%{?fedora} && 0%{?fedora} <= 32 || 0%{?rhel} && 0%{?rhel} <= 8
%define java_headless java-21-openjdk-headless %define java_devel java-1.8.0-openjdk-devel
%define java_home %{_jvmdir}/jre-21-openjdk %define java_headless java-1.8.0-openjdk-headless
%define java_home /usr/lib/jvm/java-1.8.0-openjdk
%else
%define java_devel java-11-openjdk-devel
%define java_headless java-11-openjdk-headless
%define java_home /usr/lib/jvm/java-11-openjdk
%endif
################################################################################ ################################################################################
# Build Dependencies # Build Dependencies
@ -64,10 +61,11 @@ ExclusiveArch: %{java_arches} noarch
BuildRequires: ant BuildRequires: ant
BuildRequires: %{java_devel} BuildRequires: %{java_devel}
BuildRequires: maven-local BuildRequires: javapackages-local
BuildRequires: mvn(org.slf4j:slf4j-api) BuildRequires: slf4j
BuildRequires: mvn(org.slf4j:slf4j-jdk14) BuildRequires: slf4j-jdk14
BuildRequires: mvn(org.dogtagpki.jss:jss-base) >= 5.6.0
BuildRequires: jss >= 4.11.0, jss < 5.0.0
%description %description
The Mozilla LDAP SDKs enable you to write applications which access, The Mozilla LDAP SDKs enable you to write applications which access,
@ -80,9 +78,11 @@ manage, and update the information stored in an LDAP directory.
Summary: LDAP SDK Summary: LDAP SDK
Requires: %{java_headless} Requires: %{java_headless}
Requires: mvn(org.slf4j:slf4j-api) Requires: jpackage-utils >= 0:1.5
Requires: mvn(org.slf4j:slf4j-jdk14) Requires: slf4j
Requires: mvn(org.dogtagpki.jss:jss-base) >= 5.6.0 Requires: slf4j-jdk14
Requires: jss >= 4.11.0, jss < 5.0.0
Obsoletes: ldapjdk < %{version}-%{release} Obsoletes: ldapjdk < %{version}-%{release}
Provides: ldapjdk = %{version}-%{release} Provides: ldapjdk = %{version}-%{release}
@ -113,68 +113,87 @@ Javadoc for LDAP SDK
%prep %prep
################################################################################ ################################################################################
%autosetup -n ldap-sdk-%{version}%{?phase:-}%{?phase} -p 1 %autosetup -n ldap-sdk-%{version}%{?_phase} -p 1
# flatten-maven-plugin is not available in RPM # Remove all bundled jars, we must build against build-system jars
%pom_remove_plugin org.codehaus.mojo:flatten-maven-plugin rm -f ./java-sdk/ldapjdk/lib/{jss32_stub,jsse,jnet,jaas,jndi}.jar
# specify Maven artifact locations
%mvn_file org.dogtagpki.ldap-sdk:ldapjdk ldapjdk/ldapjdk ldapjdk
%mvn_file org.dogtagpki.ldap-sdk:ldapbeans ldapjdk/ldapbeans ldapbeans
%mvn_file org.dogtagpki.ldap-sdk:ldapfilter ldapjdk/ldapfilter ldapfilt
%mvn_file org.dogtagpki.ldap-sdk:ldapsp ldapjdk/ldapsp ldapsp
%mvn_file org.dogtagpki.ldap-sdk:ldaptools ldapjdk/ldaptools ldaptools
################################################################################ ################################################################################
%build %build
################################################################################ ################################################################################
export JAVA_HOME=%{java_home} pushd java-sdk/ldapjdk/lib
build-jar-repository -s -p . jss
popd
%mvn_build ln -s /usr/lib/jvm-exports/java/{jsse,jaas,jndi}.jar java-sdk/ldapjdk/lib
pushd java-sdk
export JAVA_HOME=%{java_home}
sh -x ant dist
popd
################################################################################ ################################################################################
%install %install
################################################################################ ################################################################################
%mvn_install install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
install -m 644 java-sdk/dist/packages/ldapjdk.jar $RPM_BUILD_ROOT%{_javadir}/ldapjdk.jar
install -m 644 java-sdk/dist/packages/%{spname}.jar $RPM_BUILD_ROOT%{_javadir}/%{spname}.jar
install -m 644 java-sdk/dist/packages/%{filtname}.jar $RPM_BUILD_ROOT%{_javadir}/%{filtname}.jar
install -m 644 java-sdk/dist/packages/%{beansname}.jar $RPM_BUILD_ROOT%{_javadir}/%{beansname}.jar
ln -sf %{name}/ldapjdk.pom %{buildroot}%{_mavenpomdir}/JPP-ldapjdk.pom mkdir -p %{buildroot}%{_mavenpomdir}
ln -sf %{name}/ldapsp.pom %{buildroot}%{_mavenpomdir}/JPP-ldapsp.pom install -pm 644 java-sdk/ldapjdk/pom.xml %{buildroot}%{_mavenpomdir}/JPP-ldapjdk.pom
ln -sf %{name}/ldapfilter.pom %{buildroot}%{_mavenpomdir}/JPP-ldapfilter.pom install -pm 644 java-sdk/ldapfilter/pom.xml %{buildroot}%{_mavenpomdir}/JPP-ldapfilter.pom
ln -sf %{name}/ldapbeans.pom %{buildroot}%{_mavenpomdir}/JPP-ldapbeans.pom install -pm 644 java-sdk/ldapbeans/pom.xml %{buildroot}%{_mavenpomdir}/JPP-ldapbeans.pom
ln -sf %{name}/ldaptools.pom %{buildroot}%{_mavenpomdir}/JPP-ldaptools.pom install -pm 644 java-sdk/ldapsp/pom.xml %{buildroot}%{_mavenpomdir}/JPP-ldapsp.pom
install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/ldapjdk
cp -r java-sdk/dist/doc/* $RPM_BUILD_ROOT%{_javadocdir}/ldapjdk
################################################################################ ################################################################################
%files -n %{product_id} -f .mfiles %files -n %{product_id}
################################################################################ ################################################################################
%{_javadir}/ldapjdk.jar
%{_javadir}/%{spname}*.jar
%{_javadir}/%{filtname}*.jar
%{_javadir}/%{beansname}*.jar
%{_mavenpomdir}/JPP-ldapjdk.pom %{_mavenpomdir}/JPP-ldapjdk.pom
%{_mavenpomdir}/JPP-ldapsp.pom %{_mavenpomdir}/JPP-ldapsp.pom
%{_mavenpomdir}/JPP-ldapfilter.pom %{_mavenpomdir}/JPP-ldapfilter.pom
%{_mavenpomdir}/JPP-ldapbeans.pom %{_mavenpomdir}/JPP-ldapbeans.pom
%{_mavenpomdir}/JPP-ldaptools.pom
################################################################################ ################################################################################
%files -n %{product_id}-javadoc -f .mfiles-javadoc %files -n %{product_id}-javadoc
################################################################################ ################################################################################
%dir %{_javadocdir}/ldapjdk
%{_javadocdir}/ldapjdk/*
################################################################################ ################################################################################
%changelog %changelog
* Mon Dec 09 2024 Red Hat PKI Team <rhcs-maint@redhat.com> - 5.6.0-alpha1 * Thu Feb 08 2024 Red Hat PKI Team <rhcs-maint@redhat.com> 4.24.0-1
- Rebase to LDAP SDK 5.6.0-alpha1 - Rebase to LDAP SDK 4.24.0
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 5.5.0-3.1 * Tue Jan 16 2024 Red Hat PKI Team <rhcs-maint@redhat.com> 4.24.0-0.1
- Bump release for October 2024 mass rebuild: - Rebase to LDAP SDK 4.24.0-alpha1
Resolves: RHEL-64018
* Wed Aug 14 2024 Andrew Hughes <gnu.andrew@redhat.com> - 5.5.0-3 * Mon Jul 26 2021 Red Hat PKI Team <rhcs-maint@redhat.com> 4.23.0-1
- Rebuilt with java-21-openjdk as default JDK: - Rebase to LDAP SDK 4.23.0
https://issues.redhat.com/browse/RHEL-34597
- Resolves: RHEL-54333
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 5.5.0-2.1 * Fri Jun 11 2021 Red Hat PKI Team <rhcs-maint@redhat.com> 4.23.0-0.1
- Bump release for June 2024 mass rebuild - Rebase to LDAP SDK 4.23.0-alpha1
* Fri May 10 2024 Red Hat PKI Team <rhcs-maint@redhat.com> - 5.5.0-2 * Tue May 26 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 4.22.0-1
- Rebase to LDAP SDK 5.5.0 - Rebase to LDAP SDK 4.22.0
* Thu Oct 31 2019 Red Hat PKI Team <rhcs-maint@redhat.com> 4.21.0-2
- Bump min required JSS version to 4.6.0
* Mon Jun 10 2019 Red Hat PKI Team <rhcs-maint@redhat.com> 4.21.0-1
- Rebase to LDAP SDK 4.21.0
* Fri Aug 10 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 4.20.0-0
- Rebase to LDAP SDK 4.20.0

View File

@ -1,9 +0,0 @@
#!/bin/sh
REPO=$1
if [ "$REPO" == "" ]; then
REPO="pki-10.6"
fi
fedpkg copr-build --nowait $REPO

View File

@ -1,7 +0,0 @@
# recipients: rhcs-team
--- !Policy
product_versions:
- rhel-10
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}

View File

@ -1,3 +0,0 @@
---
inspections:
javabytecode: off

View File

@ -1 +0,0 @@
SHA512 (ldap-sdk-5.6.0-alpha1.tar.gz) = 8aafe83086dd378d5db52c5e42ec961115ae9e7add685057ede716f0ba7389b630975c34ae675e1c2e1a1b5e0519badee78d5f59a21cfb88a0f20308b9d6cdaa

View File

@ -1,7 +0,0 @@
#!/bin/sh
SOURCE=$1
TARGET=`basename $1`
cp $SOURCE $TARGET
sha512sum --tag $TARGET > sources

View File

@ -1,25 +0,0 @@
[DEFAULT]
pki_server_database_password=Secret.123
[CA]
pki_admin_email=caadmin@example.com
pki_admin_name=caadmin
pki_admin_nickname=caadmin
pki_admin_password=Secret.123
pki_admin_uid=caadmin
pki_client_database_password=Secret.123
pki_client_database_purge=False
pki_client_pkcs12_password=Secret.123
pki_ds_base_dn=dc=ca,dc=pki,dc=example,dc=com
pki_ds_database=ca
pki_ds_password=Secret.123
pki_security_domain_name=EXAMPLE
pki_ca_signing_nickname=ca_signing
pki_ocsp_signing_nickname=ca_ocsp_signing
pki_audit_signing_nickname=ca_audit_signing
pki_sslserver_nickname=sslserver
pki_subsystem_nickname=subsystem

View File

@ -1,24 +0,0 @@
#!/bin/bash -ex
# This command needs to be executed as it pulls the machine name
# dynamically.
dscreate create-template /tmp/test_dir/ds.inf
sed -i \
-e "s/;instance_name = .*/instance_name = localhost/g" \
-e "s/;root_password = .*/root_password = Secret.123/g" \
-e "s/;suffix = .*/suffix = dc=example,dc=com/g" \
-e "s/;self_sign_cert = .*/self_sign_cert = False/g" \
/tmp/test_dir/ds.inf
dscreate from-file /tmp/test_dir/ds.inf
ldapadd -H ldap://$HOSTNAME -x -D "cn=Directory Manager" -w Secret.123 << EOF
dn: dc=example,dc=com
objectClass: domain
dc: example
dn: dc=pki,dc=example,dc=com
objectClass: domain
dc: pki
EOF

View File

@ -1,27 +0,0 @@
[DEFAULT]
pki_server_database_password=Secret.123
[KRA]
pki_admin_email=kraadmin@example.com
pki_admin_name=kraadmin
pki_admin_nickname=kraadmin
pki_admin_password=Secret.123
pki_admin_uid=kraadmin
pki_client_database_password=Secret.123
pki_client_database_purge=False
pki_client_pkcs12_password=Secret.123
pki_ds_base_dn=dc=kra,dc=pki,dc=example,dc=com
pki_ds_database=kra
pki_ds_password=Secret.123
pki_security_domain_name=EXAMPLE
pki_security_domain_user=caadmin
pki_security_domain_password=Secret.123
pki_storage_nickname=kra_storage
pki_transport_nickname=kra_transport
pki_audit_signing_nickname=kra_audit_signing
pki_sslserver_nickname=sslserver
pki_subsystem_nickname=subsystem

View File

@ -1,26 +0,0 @@
---
- name: Install ldapjdk
dnf:
name: >
ldapjdk
- name: Install required packages
dnf:
name: >
389-ds-base, pki-ca, pki-kra
- name: Creates directory
file: path=/tmp/test_files state=directory
- name: Copying templates to /tmp folder
copy : src=. dest=/tmp/test_dir
- name: Setup DS Service
shell: sh /tmp/test_dir/ds-create.sh
- name: Install CA subsystem
shell: pkispawn -f /tmp/test_dir/ca.cfg -s CA -v
- name: Install KRA subsystem
shell: pkispawn -f /tmp/test_dir/kra.cfg -s KRA -v

View File

@ -1,30 +0,0 @@
- hosts: localhost
remote_user: root
tags:
- classic
roles:
- role: Test_Setup
- role: standard-test-basic
tests:
- verify_spawn_ca:
dir: .
run: "curl http://localhost:8080/ca/admin/ca/getStatus | grep '\"running\"'"
- verify_spawn_kra:
dir: .
run: "curl http://localhost:8080/kra/admin/kra/getStatus | grep '\"running\"'"
- destroy_kra:
dir: .
run: "pkidestroy -i pki-tomcat -s KRA && sleep 5"
- verify_destroy_kra:
dir: .
run: "curl http://localhost:8080/kra/admin/kra/getStatus | grep 'HTTP Status 404'"
- destroy_ca:
dir: .
run: "pkidestroy -i pki-tomcat -s CA"
- verify_destroy_ca:
dir: .
run: "curl http://localhost:8080/ca/admin/ca/getStatus &> testfile.log || true && grep -i 'failed' testfile.log"
required_packages:
- ldapjdk
- pki-ca
- pki-kra