Compare commits

..

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

13 changed files with 102 additions and 277 deletions

41
.gitignore vendored
View File

@ -1,40 +1 @@
tomcatjss-1.2.0.tar.gz
/tomcatjss-2.0.0.tar.gz
/tomcatjss-2.1.1.tar.gz
/tomcatjss-6.0.0.tar.gz
/tomcatjss-6.0.1.tar.gz
/tomcatjss-6.0.2.tar.gz
/tomcatjss-7.0.0.tar.gz
/tomcatjss-7.1.0.tar.gz
/tomcatjss-7.1.1.tar.gz
/tomcatjss-7.1.2.tar.gz
/tomcatjss-7.1.3.tar.gz
/tomcatjss-7.1.4.tar.gz
/tomcatjss-7.2.0.tar.gz
/tomcatjss-7.2.1.tar.gz
/tomcatjss-7.2.2.tar.gz
/tomcatjss-7.2.3.tar.gz
/tomcatjss-7.2.4.tar.gz
/tomcatjss-7.3.0.tar.gz
/tomcatjss-7.3.1.tar.gz
/tomcatjss-7.3.2.tar.gz
/tomcatjss-7.3.3.tar.gz
/tomcatjss-7.3.4.tar.gz
/tomcatjss-7.3.5.tar.gz
/tomcatjss-7.3.6.tar.gz
/tomcatjss-7.3.7.tar.gz
/tomcatjss-7.4.0.tar.gz
/tomcatjss-7.4.1.tar.gz
/tomcatjss-7.5.0-a1.tar.gz
/tomcatjss-7.5.0-b2.tar.gz
/tomcatjss-7.5.0.tar.gz
/tomcatjss-7.6.0.tar.gz
/tomcatjss-7.6.1.tar.gz
/tomcatjss-8.0.0-alpha1.tar.gz
/tomcatjss-8.0.0.tar.gz
/tomcatjss-8.2.0-beta1.tar.gz
/tomcatjss-8.2.0-beta2.tar.gz
/tomcatjss-8.2.0.tar.gz
/tomcatjss-8.3.0-beta1.tar.gz
/tomcatjss-8.3.0.tar.gz
/tomcatjss-8.4.0.tar.gz
SOURCES/tomcatjss-7.8.0.tar.gz

1
.tomcatjss.metadata Normal file
View File

@ -0,0 +1 @@
b866d5baa11685960fa00b600c33af1c2eab55e3 SOURCES/tomcatjss-7.8.0.tar.gz

View File

@ -5,29 +5,21 @@ Name: tomcatjss
%global product_id idm-tomcatjss
# Upstream version number:
%global major_version 8
%global minor_version 4
%global major_version 7
%global minor_version 8
%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 1
# Development phase:
# - development (unsupported): alpha<n> where n >= 1
# - stabilization (unsupported): beta<n> where n >= 1
# - GA/update (supported): <none>
#global phase
%undefine timestamp
%undefine commit_id
Summary: JSS Connector for Apache Tomcat
URL: https://github.com/dogtagpki/tomcatjss
License: 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}
Release: %{release_number}%{?phase:.}%{?phase}%{?timestamp:.}%{?timestamp}%{?commit_id:.}%{?commit_id}%{?dist}
Release: %{release_number}%{?_timestamp}%{?_commit_id}%{?dist}
#global _phase -alpha1
# To generate the source tarball:
# $ git clone https://github.com/dogtagpki/tomcatjss.git
@ -37,7 +29,7 @@ Release: %{release_number}%{?phase:.}%{?phase}%{?timestamp:.}%{?timesta
# --prefix tomcatjss-VERSION/ \
# -o tomcatjss-VERSION.tar.gz \
# <version tag>
Source: https://github.com/dogtagpki/tomcatjss/archive/v%{version}%{?phase:-}%{?phase}/tomcatjss-%{version}%{?phase:-}%{?phase}.tar.gz
Source: https://github.com/dogtagpki/tomcatjss/archive/v%{version}%{?_phase}/tomcatjss-%{version}%{?_phase}.tar.gz
# To create a patch for all changes since a version tag:
# $ git format-patch \
@ -46,15 +38,19 @@ Source: https://github.com/dogtagpki/tomcatjss/archive/v%{version}%{?p
# > tomcatjss-VERSION-RELEASE.patch
# Patch: tomcatjss-VERSION-RELEASE.patch
BuildArch: noarch
################################################################################
# Java
################################################################################
%define java_devel java-17-openjdk-devel
%define java_headless java-17-openjdk-headless
%define java_home %{_jvmdir}/jre-17-openjdk
%if 0%{?fedora} && 0%{?fedora} <= 32 || 0%{?rhel} && 0%{?rhel} <= 8
%define java_devel java-1.8.0-openjdk-devel
%define java_headless java-1.8.0-openjdk-headless
%define java_home /usr/lib/jvm/jre-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/jre-11-openjdk
%endif
################################################################################
# Build Dependencies
@ -75,14 +71,10 @@ BuildRequires: slf4j
BuildRequires: slf4j-jdk14
# JSS
BuildRequires: jss = 5.4
BuildRequires: jss >= 4.11.0, jss < 5.0.0
# Tomcat
%if 0%{?rhel} && ! 0%{?eln}
BuildRequires: pki-servlet-engine >= 1:9.0.7
%else
BuildRequires: tomcat >= 1:9.0.7
%endif
BuildRequires: tomcat
%description
JSS Connector for Apache Tomcat, installed via the tomcatjss package,
@ -106,14 +98,10 @@ Requires: slf4j
Requires: slf4j-jdk14
# JSS
Requires: jss = 5.4
Requires: jss >= 4.11.0, jss < 5.0.0
# Tomcat
%if 0%{?rhel} && ! 0%{?eln}
Requires: pki-servlet-engine >= 1:9.0.7
%else
Requires: tomcat >= 1:9.0.7
%endif
Requires: tomcat
Obsoletes: tomcatjss < %{version}-%{release}
Provides: tomcatjss = %{version}-%{release}
@ -139,34 +127,22 @@ Services (NSS).
%prep
################################################################################
%autosetup -n tomcatjss-%{version}%{?phase:-}%{?phase} -p 1
################################################################################
%build
################################################################################
export JAVA_HOME=%{java_home}
./build.sh \
%{?_verbose:-v} \
--name=%{product_id} \
--work-dir=%{_vpath_builddir} \
--version=%{version} \
--jni-dir=%{_jnidir} \
dist
%autosetup -n tomcatjss-%{version}%{?_phase} -p 1
################################################################################
%install
################################################################################
./build.sh \
%{?_verbose:-v} \
--name=%{product_id} \
--work-dir=%{_vpath_builddir} \
--version=%{version} \
--java-dir=%{_javadir} \
--doc-dir=%{_docdir} \
--install-dir=%{buildroot} \
# get Tomcat <major>.<minor> version number
tomcat_version=`/usr/sbin/tomcat version | sed -n 's/Server number: *\([0-9]\+\.[0-9]\+\).*/\1/p'`
app_server=tomcat-$tomcat_version
ant -f build.xml \
-Dversion=%{version} \
-Dsrc.dir=$app_server \
-Djnidir=%{_jnidir} \
-Dinstall.doc.dir=%{buildroot}%{_docdir}/%{product_id} \
-Dinstall.jar.dir=%{buildroot}%{_javadir} \
install
################################################################################
@ -182,31 +158,77 @@ export JAVA_HOME=%{java_home}
################################################################################
%changelog
* Wed May 31 2023 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.4.0-1
- Rebase to Tomcat JSS 8.4.0
* Thu Feb 08 2024 Red Hat PKI Team <rhcs-maint@redhat.com> 7.8.0-1
- Rebase to TomcatJSS 7.8.0
* Fri Feb 10 2023 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.3.0-1
- Rebase to Tomcat JSS 8.3.0
* Tue Jan 16 2024 Red Hat PKI Team <rhcs-maint@redhat.com> 7.8.0-0.1
- Rebase to TomcatJSS 7.8.0-alpha1
* Wed Nov 30 2022 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.3.0-0.2.beta1
- Rebase to Tomcat JSS 8.3.0-beta1
* Mon Jan 15 2024 Red Hat PKI Team <rhcs-maint@redhat.com> 7.7.3-1
- Replace pki-servlet-engine with tomcat
* Thu Jun 30 2022 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.2.0-1
- Rebase to Tomcat JSS 8.2.0
* Mon Nov 15 2021 Red Hat PKI Team <rhcs-maint@redhat.com> 7.7.1-1
- Rebase to TomcatJSS 7.7.1
* Mon May 02 2022 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.2.0-0.3.beta2
- Rebase to Tomcat JSS 8.2.0-beta2
- Rename packages to idm-tomcatjss
* Mon Jul 26 2021 Red Hat PKI Team <rhcs-maint@redhat.com> 7.7.0-1
- Rebase to TomcatJSS 7.7.0
* Mon Apr 18 2022 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.2.0-0.2.beta1
- Rebase to Tomcat JSS 8.2.0-beta1
* Fri Jun 11 2021 Red Hat PKI Team <rhcs-maint@redhat.com> 7.7.0-0.1
- Rebase to TomcatJSS 7.7.0-alpha1
* Tue Oct 05 2021 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.0.0-1
- Rebase to Tomcat JSS 8.0.0
* Tue Nov 17 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 7.6.1-1
- Rebase to TomcatJSS 7.6.1
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 8.0.0-0.2.alpha1
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Wed Oct 28 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 7.6.0-2
- Bump dependency to JSS 4.8.0
- Remove unsupported platforms
* Fri Jun 25 2021 Red Hat PKI Team <rhcs-maint@redhat.com> - 8.0.0-0.1
- Rebase to Tomcat JSS 8.0.0-alpha1
* Tue Oct 20 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 7.6.0-1
- Rebase to TomcatJSS 7.6.0
* Thu Jul 09 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 7.5.0-1
- Rebase to TomcatJSS 7.5.0
* Thu Jun 25 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 7.5.0-0.2
- Rebase to TomcatJSS 7.5.0-a2
* Tue May 26 2020 Red Hat PKI Team <rhcs-maint@redhat.com> 7.5.0-0.1
- Rebase to TomcatJSS 7.5.0-a1
* Thu Oct 31 2019 Red Hat PKI Team <rhcs-maint@redhat.com> 7.4.1-2
- Bump dependency to JSS 4.6.0
* Wed Jun 12 2019 Red Hat PKI Team <rhcs-maint@redhat.com> 7.4.1-1
- Rebase to TomcatJSS 7.4.1
* Wed Apr 24 2019 Red Hat PKI Team <rhcs-maint@redhat.com> 7.4.0-1
- Rebase to TomcatJSS 7.4.0
* Fri Oct 05 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.6-1
- Rebase to TomcatJSS 7.3.6
* Mon Aug 13 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.5-1
- Rebase to TomcatJSS 7.3.5
* Tue Aug 07 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.4-1
- Rebase to TomcatJSS 7.3.4
* Tue Aug 07 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.3-2
- Red Hat Bugzilla #1612063 - Do not override system crypto policy (support TLS 1.3)
* Fri Jul 20 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.3-1
- Rebase to TomcatJSS 7.3.3
* Thu Jul 05 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.2-1
- Rebase to TomcatJSS 7.3.2
* Fri Jun 15 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.1-1
- Fix Tomcat dependencies
- Rebase to TomcatJSS 7.3.1
* Thu Apr 12 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.0-1
- Clean up spec file
- Rebase to TomcatJSS 7.3.0 final
* Thu Mar 15 2018 Red Hat PKI Team <rhcs-maint@redhat.com> 7.3.0-0.2
- Rebase to TomcatJSS 7.3.0 beta

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-9
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 (tomcatjss-8.4.0.tar.gz) = 799d3b36d5b7f6193450a8e9d9d3d14856c915343d3eff11f5121174f7379e2db0209d5a8cbf6de0fc834cd4843ae586ee48137195b6a70e15f89031462601ad

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 $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 tomcatjss
dnf:
name: >
tomcatjss
- 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 '<Status>running</Status>'"
- verify_spawn_kra:
dir: .
run: "curl http://localhost:8080/kra/admin/kra/getStatus | grep '<Status>running</Status>'"
- 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 'Connection refused' testfile.log"
required_packages:
- tomcatjss
- pki-ca
- pki-kra