From 01299bf25b53a4f632c20b87714d5e1b314450da Mon Sep 17 00:00:00 2001
From: Thomas <>
Date: Tue, 18 Feb 2025 10:38:34 +0100
Subject: feat(sign): add RSASSA-PSS support
---
.../src/main/resources/resources/schemas/MOA-SPSS-config-3.2.0.xsd | 6 ++++++
1 file changed, 6 insertions(+)
(limited to 'moaSig/common')
diff --git a/moaSig/common/src/main/resources/resources/schemas/MOA-SPSS-config-3.2.0.xsd b/moaSig/common/src/main/resources/resources/schemas/MOA-SPSS-config-3.2.0.xsd
index d9cecf1..57c2e1d 100644
--- a/moaSig/common/src/main/resources/resources/schemas/MOA-SPSS-config-3.2.0.xsd
+++ b/moaSig/common/src/main/resources/resources/schemas/MOA-SPSS-config-3.2.0.xsd
@@ -98,6 +98,7 @@
+
@@ -131,6 +132,11 @@
+
+
+
+
+
--
cgit v1.2.3
From 98967fdd5649dafabc4b225a0496cab4ec034d96 Mon Sep 17 00:00:00 2001
From: Thomas Lenz
Date: Mon, 4 Aug 2025 17:33:33 +0200
Subject: build(core): switch to gradle 8.6
---
moaSig/build.gradle | 160 ++++++++++++------------
moaSig/common/build.gradle | 36 ++++--
moaSig/gradle/wrapper/gradle-wrapper.jar | Bin 55627 -> 59203 bytes
moaSig/gradle/wrapper/gradle-wrapper.properties | 4 +-
moaSig/gradlew | 53 +++++---
moaSig/gradlew.bat | 43 ++++---
moaSig/moa-asic/build.gradle | 97 +++++++-------
moaSig/moa-sig-lib/build.gradle | 86 +++++++------
moaSig/moa-sig/build.gradle | 141 +++++++++++----------
9 files changed, 325 insertions(+), 295 deletions(-)
(limited to 'moaSig/common')
diff --git a/moaSig/build.gradle b/moaSig/build.gradle
index 79cda52..3dc1893 100644
--- a/moaSig/build.gradle
+++ b/moaSig/build.gradle
@@ -1,98 +1,96 @@
-buildscript {
- repositories {
- maven {
- url "https://plugins.gradle.org/m2/"
+plugins {
+ id 'java-library'
+ id 'eclipse'
+ id 'maven-publish'
+}
+
+allprojects {
+ version = '3.2.5-SNAPSHOT'
+
+ repositories {
+ mavenLocal()
+ mavenCentral()
+ maven {
+ url "https://apps.egiz.gv.at/maven/"
+ mavenContent {
+ releasesOnly()
+ }
+ }
+ maven {
+ url "https://apps.egiz.gv.at/maven-snapshot/"
+ mavenContent {
+ snapshotsOnly()
+ }
+ }
}
- }
- dependencies {
- classpath "com.bmuschko:gradle-tomcat-plugin:2.2.4"
- }
}
subprojects {
apply plugin: 'java-library'
apply plugin: 'eclipse'
apply plugin: 'maven-publish'
- apply plugin: 'maven'
-
- version = '3.2.5-SNAPSHOT'
- repositories {
- mavenCentral()
-
- maven {
- url "https://apps.egiz.gv.at/maven/"
- mavenContent {
- releasesOnly()
- }
- }
- maven {
- url "https://apps.egiz.gv.at/maven-snapshot/"
- mavenContent {
- snapshotsOnly()
- }
- }
-
- }
-
dependencies {
testImplementation 'junit:junit:4.13.2'
}
-
- jar { manifest.attributes provider: 'EGIZ', 'Specification-Version': getCheckedOutGitCommitHash(), 'Implementation-Version': project.version }
- compileJava {
- sourceCompatibility = 1.8
- targetCompatibility = 1.8
- }
+ java {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+ withJavadocJar()
+ withSourcesJar()
+ }
+
+ tasks.withType(JavaCompile).configureEach {
+ options.compilerArgs << '-Xlint:-options'
+ }
- tasks.withType(JavaCompile) {
- options.compilerArgs << '-Xlint:-options'
- }
-
- publishing {
- publications {
- mavenJava(MavenPublication) {
- from components.java
- // more goes in here
- }
- }
- repositories {
- maven {
- // change to point to your repo, e.g. http://my.org/repo
- url = "$buildDir/repo"
- }
- mavenLocal()
- }
+ tasks.withType(Javadoc).configureEach {
+ failOnError = false
+ options.addStringOption('Xdoclint:none', '-quiet')
}
-
- task deployJar(type: Jar)
- configurations {
- deployerJars
-
- }
-
- dependencies {
- deployerJars "org.apache.maven.wagon:wagon-ssh:3.4.3"
-
- }
+ jar {
+ manifest {
+ attributes(
+ provider: 'EGIZ',
+ 'Specification-Version': getCheckedOutGitCommitHash(),
+ 'Implementation-Version': project.version
+ )
+ }
+ }
- uploadArchives {
- repositories.mavenDeployer {
- configuration = configurations.deployerJars
- repository(url: "sftp://apps.egiz.gv.at/maven") {
- authentication(userName: System.getenv("EGIZ_MAVEN_USER"), password: System.getenv("EGIZ_MAVEN_PASSWORD"))
-
- }
- snapshotRepository(url: "sftp://apps.egiz.gv.at/maven-snapshot") {
- authentication(userName: System.getenv("EGIZ_MAVEN_USER"), password: System.getenv("EGIZ_MAVEN_PASSWORD"))
-
- }
- }
- }
-
-
+ publishing {
+ publications {
+ mavenJava(MavenPublication) {
+ from components.java
+ }
+ }
+ repositories {
+ maven {
+ url = uri("$buildDir/repo")
+ }
+ mavenLocal()
+ maven {
+ name = "egizReleases"
+ url = uri("sftp://apps.egiz.gv.at/maven")
+ credentials {
+ username = System.getenv("EGIZ_MAVEN_USER")
+ password = System.getenv("EGIZ_MAVEN_PASSWORD")
+ }
+ allowInsecureProtocol = true
+ }
+ maven {
+ name = "egizSnapshots"
+ url = uri("sftp://apps.egiz.gv.at/maven-snapshot")
+ credentials {
+ username = System.getenv("EGIZ_MAVEN_USER")
+ password = System.getenv("EGIZ_MAVEN_PASSWORD")
+ }
+ allowInsecureProtocol = true
+ }
+ }
+ }
}
def getCheckedOutGitCommitHash() {
@@ -100,7 +98,7 @@ def getCheckedOutGitCommitHash() {
def takeFromHash = 40
def head = new File(gitFolder + "HEAD").text.split(":")
def isCommit = head.length == 1
- if(isCommit) return head[0].trim().take(takeFromHash)
+ if (isCommit) return head[0].trim().take(takeFromHash)
def refHead = new File(gitFolder + head[1].trim())
- refHead.text.trim().take takeFromHash
+ refHead.text.trim().take(takeFromHash)
}
diff --git a/moaSig/common/build.gradle b/moaSig/common/build.gradle
index 5f12e76..6054eff 100644
--- a/moaSig/common/build.gradle
+++ b/moaSig/common/build.gradle
@@ -1,24 +1,34 @@
+plugins {
+ id 'java-library'
+}
+
dependencies {
- implementation files('../libs/iaik_jce_full_signed-6.1_moa.jar')
- api 'org.slf4j:slf4j-api:1.7.36'
- api 'xerces:xercesImpl:2.12.2'
- api 'xalan:xalan:2.7.1'
- api group: 'xalan', name: 'serializer', version: '2.7.1'
- api 'joda-time:joda-time:2.12.7'
- api 'jaxen:jaxen:1.2.0'
+ implementation files('../libs/iaik_jce_full_signed-6.1_moa.jar')
+
+ api 'org.slf4j:slf4j-api:1.7.36'
+ api 'xerces:xercesImpl:2.12.2'
+ api 'xalan:xalan:2.7.1'
+ api 'xalan:serializer:2.7.1'
+ api 'joda-time:joda-time:2.12.7'
+ api 'jaxen:jaxen:1.2.0'
}
-task testJar(type: Jar, dependsOn: testClasses) {
+java {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+ withJavadocJar()
+ withSourcesJar()
+}
+
+tasks.register('testJar', Jar) {
+ archiveClassifier.set('tests')
from sourceSets.test.output
- classifier = 'tests'
}
configurations {
- testArtifacts.extendsFrom testCompile
+ testArtifacts
}
artifacts {
- testArtifacts testJar
- //archives testJar
+ testArtifacts(tasks.named('testJar'))
}
-
diff --git a/moaSig/gradle/wrapper/gradle-wrapper.jar b/moaSig/gradle/wrapper/gradle-wrapper.jar
index 75ae3ac..e708b1c 100644
Binary files a/moaSig/gradle/wrapper/gradle-wrapper.jar and b/moaSig/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/moaSig/gradle/wrapper/gradle-wrapper.properties b/moaSig/gradle/wrapper/gradle-wrapper.properties
index e6fc1b1..17655d0 100644
--- a/moaSig/gradle/wrapper/gradle-wrapper.properties
+++ b/moaSig/gradle/wrapper/gradle-wrapper.properties
@@ -1,5 +1,5 @@
-distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
-zipStorePath=wrapper/dists
+distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip
zipStoreBase=GRADLE_USER_HOME
+zipStorePath=wrapper/dists
diff --git a/moaSig/gradlew b/moaSig/gradlew
index cccdd3d..4f906e0 100755
--- a/moaSig/gradlew
+++ b/moaSig/gradlew
@@ -1,5 +1,21 @@
#!/usr/bin/env sh
+#
+# Copyright 2015 the original author or authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# https://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
##############################################################################
##
## Gradle start up script for UN*X
@@ -28,7 +44,7 @@ APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-DEFAULT_JVM_OPTS=""
+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
@@ -66,6 +82,7 @@ esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
+
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
@@ -109,10 +126,11 @@ if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi
-# For Cygwin, switch paths to Windows format before running java
-if $cygwin ; then
+# For Cygwin or MSYS, switch paths to Windows format before running java
+if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
+
JAVACMD=`cygpath --unix "$JAVACMD"`
# We build the pattern for arguments to be converted via cygpath
@@ -138,19 +156,19 @@ if $cygwin ; then
else
eval `echo args$i`="\"$arg\""
fi
- i=$((i+1))
+ i=`expr $i + 1`
done
case $i in
- (0) set -- ;;
- (1) set -- "$args0" ;;
- (2) set -- "$args0" "$args1" ;;
- (3) set -- "$args0" "$args1" "$args2" ;;
- (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
- (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
- (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
- (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
- (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
- (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
+ 0) set -- ;;
+ 1) set -- "$args0" ;;
+ 2) set -- "$args0" "$args1" ;;
+ 3) set -- "$args0" "$args1" "$args2" ;;
+ 4) set -- "$args0" "$args1" "$args2" "$args3" ;;
+ 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
+ 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
+ 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
+ 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
+ 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
@@ -159,14 +177,9 @@ save () {
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
echo " "
}
-APP_ARGS=$(save "$@")
+APP_ARGS=`save "$@"`
# Collect all arguments for the java command, following the shell quoting and substitution rules
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
-# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
-if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
- cd "$(dirname "$0")"
-fi
-
exec "$JAVACMD" "$@"
diff --git a/moaSig/gradlew.bat b/moaSig/gradlew.bat
index e95643d..ac1b06f 100644
--- a/moaSig/gradlew.bat
+++ b/moaSig/gradlew.bat
@@ -1,3 +1,19 @@
+@rem
+@rem Copyright 2015 the original author or authors.
+@rem
+@rem Licensed under the Apache License, Version 2.0 (the "License");
+@rem you may not use this file except in compliance with the License.
+@rem You may obtain a copy of the License at
+@rem
+@rem https://www.apache.org/licenses/LICENSE-2.0
+@rem
+@rem Unless required by applicable law or agreed to in writing, software
+@rem distributed under the License is distributed on an "AS IS" BASIS,
+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+@rem See the License for the specific language governing permissions and
+@rem limitations under the License.
+@rem
+
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@@ -13,15 +29,18 @@ if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
+
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-set DEFAULT_JVM_OPTS=
+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
-if "%ERRORLEVEL%" == "0" goto init
+if "%ERRORLEVEL%" == "0" goto execute
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
@@ -35,7 +54,7 @@ goto fail
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
-if exist "%JAVA_EXE%" goto init
+if exist "%JAVA_EXE%" goto execute
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
@@ -45,28 +64,14 @@ echo location of your Java installation.
goto fail
-:init
-@rem Get command-line arguments, handling Windows variants
-
-if not "%OS%" == "Windows_NT" goto win9xME_args
-
-:win9xME_args
-@rem Slurp the command line arguments.
-set CMD_LINE_ARGS=
-set _SKIP=2
-
-:win9xME_args_slurp
-if "x%~1" == "x" goto execute
-
-set CMD_LINE_ARGS=%*
-
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
@rem Execute Gradle
-"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
:end
@rem End local scope for the variables with windows NT shell
diff --git a/moaSig/moa-asic/build.gradle b/moaSig/moa-asic/build.gradle
index 0a8fd83..b2b7299 100644
--- a/moaSig/moa-asic/build.gradle
+++ b/moaSig/moa-asic/build.gradle
@@ -1,30 +1,33 @@
-//plugins {
-// id 'com.intershop.gradle.jaxb' version '5.1.0'
-//}
+plugins {
+ id 'java-library'
+ id 'distribution'
+}
-apply plugin: 'java-library-distribution'
+java {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+}
distributions {
- main{
- distributionBaseName = 'MOA-ASIC'
- }
+ main {
+ distributionBaseName.set('MOA-ASIC')
+ }
}
configurations {
jaxb
-
}
dependencies {
- jaxb group: 'com.sun.xml.bind', name: 'jaxb-xjc', version: '3.0.2'
- jaxb group: 'org.glassfish.jaxb', name: 'jaxb-runtime', version: '3.0.2'
+ jaxb 'com.sun.xml.bind:jaxb-xjc:3.0.2'
+ jaxb 'org.glassfish.jaxb:jaxb-runtime:3.0.2'
- implementation project(':common')
+ implementation project(':common')
implementation project(':moa-sig-lib')
- api 'jakarta.xml.bind:jakarta.xml.bind-api:3.0.1'
- api 'jakarta.xml.ws:jakarta.xml.ws-api:3.0.1'
- implementation group: 'org.slf4j', name: 'log4j-over-slf4j', version: '1.7.36'
+ api 'jakarta.xml.bind:jakarta.xml.bind-api:3.0.1'
+ api 'jakarta.xml.ws:jakarta.xml.ws-api:3.0.1'
+ implementation 'org.slf4j:log4j-over-slf4j:1.7.36'
}
sourceSets {
@@ -35,48 +38,34 @@ sourceSets {
}
}
-/*
-jaxb {
- // generate java code from schema
- javaGen {
- //generates a 'project' schema file from existing java code
- posConfig {
- schema = file('src/main/resources/schemas/asic.xsd')
- packageName = 'at.gv.egiz.asic'
- outputDir = file( "${projectDir}/src/generated/java" )
- }
+tasks.register('jaxb') {
+ group = 'build'
+ description = 'Generates Java classes from XSD using JAXB'
+
+ doLast {
+ def jaxbTargetDir = file("${projectDir}/src/generated/java")
+ jaxbTargetDir.mkdirs()
+
+ ant.taskdef(
+ name: 'xjc',
+ classname: 'com.sun.tools.xjc.XJCTask',
+ classpath: configurations.jaxb.asPath
+ )
+
+ ant.xjc(
+ destdir: jaxbTargetDir.path,
+ package: 'at.gv.egiz.asic',
+ schema: 'src/main/resources/schemas/asic.xsd'
+ )
}
-
}
-*/
-
-task jaxb () {
- // output directory
- def jaxbTargetDir = file( "${projectDir}/src/generated/java" )
- //jaxbTargetDirMoaSig = file( jaxbTargetDir.path )
-
- // perform actions
- doLast {
- jaxbTargetDir.mkdirs()
-
- ant.taskdef(name: 'xjc', classname: 'com.sun.tools.xjc.XJCTask', classpath: configurations.jaxb.asPath)
- //ant.jaxbTargetDirMoaSig = jaxbTargetDir
-
- // MOA Sig
- ant.xjc(
- destdir: jaxbTargetDir.path,
- package: 'at.gv.egiz.asic',
- schema: 'src/main/resources/schemas/asic.xsd'
- )
- }
-}
-
-task releases(type: Copy) {
- //from jar.outputs
- from distZip.outputs
- from distTar.outputs
- into rootDir.toString() + "/releases/" + version
+tasks.register('releases', Copy) {
+ dependsOn tasks.named('distZip'), tasks.named('distTar')
+ from(tasks.named('distZip'))
+ from(tasks.named('distTar'))
+ into layout.projectDirectory.dir("releases/${version}")
}
-task publishPubNamePublicationToMavenLocal {}
+// This is a placeholder – only include if needed by CI or to avoid errors
+tasks.register('publishPubNamePublicationToMavenLocal') {}
diff --git a/moaSig/moa-sig-lib/build.gradle b/moaSig/moa-sig-lib/build.gradle
index 34fec09..ee46ed9 100644
--- a/moaSig/moa-sig-lib/build.gradle
+++ b/moaSig/moa-sig-lib/build.gradle
@@ -1,48 +1,56 @@
-apply plugin: 'java-library-distribution'
-apply plugin: 'maven-publish'
+plugins {
+ id 'java-library'
+ id 'distribution'
+ id 'maven-publish'
+}
+
+java {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+}
distributions {
main {
- distributionBaseName = 'moa-spss-lib'
+ distributionBaseName.set('moa-spss-lib')
}
}
-dependencies {
- implementation project(':common')
- testImplementation project(path: ':common', configuration: 'testArtifacts')
-
- api fileTree(dir: '../libs', include: '*.jar')
- //api fileTree(dir: '../libs_debug', include: '*.jar')
-
- api group: 'at.gv.egovernment.moa.sig', name: 'tsl-lib', version: '2.1.5'
- api 'commons-logging:commons-logging:1.2'
- api 'commons-io:commons-io:2.16.1'
- api 'commons-codec:commons-codec:1.16.0'
- api 'org.apache.axis:axis-jaxrpc:1.4'
- api 'org.xerial:sqlite-jdbc:3.46.1.0'
- api 'javax.activation:activation:1.1.1'
- api 'jakarta.xml.bind:jakarta.xml.bind-api:3.0.1'
- api 'com.sun.xml.bind:jaxb-core:3.0.2'
- api 'com.sun.xml.bind:jaxb-impl:3.0.2'
- api 'org.postgresql:postgresql:42.7.1'
- api group: 'org.apache.pdfbox', name: 'pdfbox', version: '2.0.32'
- api group: 'org.apache.pdfbox', name: 'pdfbox-tools', version: '2.0.32'
- api group: 'org.apache.pdfbox', name: 'pdfbox-app', version: '2.0.32'
- api group: 'org.apache.pdfbox', name: 'preflight', version: '2.0.32'
- api group: 'org.apache.pdfbox', name: 'preflight-app', version: '2.0.32'
- api group: 'org.apache.commons', name: 'commons-lang3', version: '3.16.0'
- api group: 'org.apache.httpcomponents', name: 'httpclient-cache', version: '4.5.14'
- api group: 'org.slf4j', name: 'jcl-over-slf4j', version: '1.7.36'
-
- testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-migrationsupport', version: '5.10.1'
- testImplementation group: 'org.junit.platform', name: 'junit-platform-engine', version: '1.10.1'
- testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.10.1'
- testImplementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.13'
+dependencies {
+ implementation project(':common')
+ testImplementation project(path: ':common', configuration: 'testArtifacts')
+
+ api fileTree(dir: '../libs', include: ['*.jar'])
+ // api fileTree(dir: '../libs_debug', include: ['*.jar'])
+
+ api 'at.gv.egovernment.moa.sig:tsl-lib:2.2.0-SNAPSHOT'
+ api 'commons-logging:commons-logging:1.2'
+ api 'commons-io:commons-io:2.16.1'
+ api 'commons-codec:commons-codec:1.16.0'
+ api 'org.apache.axis:axis-jaxrpc:1.4'
+ api 'org.xerial:sqlite-jdbc:3.46.1.0'
+ api 'javax.activation:activation:1.1.1'
+ api 'jakarta.xml.bind:jakarta.xml.bind-api:3.0.1'
+ api 'com.sun.xml.bind:jaxb-core:3.0.2'
+ api 'com.sun.xml.bind:jaxb-impl:3.0.2'
+ api 'org.postgresql:postgresql:42.7.1'
+
+ api 'org.apache.pdfbox:pdfbox:2.0.32'
+ api 'org.apache.pdfbox:pdfbox-tools:2.0.32'
+ api 'org.apache.pdfbox:pdfbox-app:2.0.32'
+ api 'org.apache.pdfbox:preflight:2.0.32'
+ api 'org.apache.pdfbox:preflight-app:2.0.32'
+ api 'org.apache.commons:commons-lang3:3.16.0'
+ api 'org.apache.httpcomponents:httpclient-cache:4.5.14'
+ api 'org.slf4j:jcl-over-slf4j:1.7.36'
+
+ testImplementation 'org.junit.jupiter:junit-jupiter-migrationsupport:5.10.1'
+ testImplementation 'org.junit.platform:junit-platform-engine:1.10.1'
+ testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.1'
+ testImplementation 'ch.qos.logback:logback-classic:1.2.13'
}
-task releases(type: Copy) {
- //from jar.outputs
- from distZip.outputs
- //from distTar.outputs
- into rootDir.toString() + "/releases/" + version
+tasks.register('releases', Copy) {
+ dependsOn(tasks.named('distZip')) // Ensure distZip runs first
+ from(tasks.named('distZip'))
+ into layout.projectDirectory.dir("releases/${version}")
}
diff --git a/moaSig/moa-sig/build.gradle b/moaSig/moa-sig/build.gradle
index 423ea20..eba2e76 100644
--- a/moaSig/moa-sig/build.gradle
+++ b/moaSig/moa-sig/build.gradle
@@ -1,33 +1,40 @@
-apply plugin: 'war'
-apply plugin: 'eclipse'
-apply plugin: 'eclipse-wtp'
-apply plugin: 'distribution'
-apply plugin: 'maven-publish'
+plugins {
+ id 'java-library'
+ id 'war'
+ id 'eclipse'
+ id 'eclipse-wtp'
+ id 'distribution'
+ id 'maven-publish'
+}
+
+java {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+}
configurations {
jaxb
}
dependencies {
- jaxb group: 'com.sun.xml.bind', name: 'jaxb-xjc', version: '3.0.2'
- jaxb group: 'org.glassfish.jaxb', name: 'jaxb-runtime', version: '3.0.2'
+ jaxb 'com.sun.xml.bind:jaxb-xjc:3.0.2'
+ jaxb 'org.glassfish.jaxb:jaxb-runtime:3.0.2'
- implementation project(':common')
- implementation project(':moa-sig-lib')
+ implementation project(':common')
+ implementation project(':moa-sig-lib')
implementation project(':moa-asic')
- implementation fileTree(dir: 'libs', include: '*.jar')
- compileOnly 'javax.servlet:javax.servlet-api:3.1.0'
- implementation 'commons-discovery:commons-discovery:0.5'
- implementation 'org.apache.logging.log4j:log4j-1.2-api:2.22.1'
- implementation group: 'org.slf4j', name: 'log4j-over-slf4j', version: '1.7.36'
- implementation group: 'javax.jws', name: 'javax.jws-api', version: '1.1'
- implementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.13'
+ implementation fileTree(dir: 'libs', include: ['*.jar'])
+ compileOnly 'javax.servlet:javax.servlet-api:3.1.0'
+ implementation 'commons-discovery:commons-discovery:0.5'
+ implementation 'org.apache.logging.log4j:log4j-1.2-api:2.22.1'
+ implementation 'org.slf4j:log4j-over-slf4j:1.7.36'
+ implementation 'javax.jws:javax.jws-api:1.1'
+ implementation 'ch.qos.logback:logback-classic:1.2.13'
- testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-migrationsupport', version: '5.10.1'
- testImplementation group: 'org.junit.platform', name: 'junit-platform-engine', version: '1.10.1'
- testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.10.1'
- testImplementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.13'
-
+ testImplementation 'org.junit.jupiter:junit-jupiter-migrationsupport:5.10.1'
+ testImplementation 'org.junit.platform:junit-platform-engine:1.10.1'
+ testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.1'
+ testImplementation 'ch.qos.logback:logback-classic:1.2.13'
}
sourceSets {
@@ -38,66 +45,66 @@ sourceSets {
}
}
-war {
- archiveBaseName = "moa-spss"
- duplicatesStrategy = DuplicatesStrategy.EXCLUDE
-}
-
-
-task jaxb () {
- // output directory
- def jaxbTargetDir = file( "${projectDir}/src/generated/java" )
+tasks.register('jaxb') {
+ group = 'build'
+ description = 'Generates Java classes from XSD using JAXB'
- // perform actions
doLast {
+ def jaxbTargetDir = file("${projectDir}/src/generated/java")
jaxbTargetDir.mkdirs()
- ant.taskdef(name: 'xjc', classname: 'com.sun.tools.xjc.XJCTask', classpath: configurations.jaxb.asPath)
+ ant.taskdef(
+ name: 'xjc',
+ classname: 'com.sun.tools.xjc.XJCTask',
+ classpath: configurations.jaxb.asPath
+ )
- // MOA Sig
ant.xjc(
- destdir: jaxbTargetDir.path,
- package: 'at.gv.egiz.moasig',
- schema: 'src/main/resources/resources/schemas/MOA-SPSS-3.1.2.xsd'
+ destdir: jaxbTargetDir.path,
+ package: 'at.gv.egiz.moasig',
+ schema: 'src/main/resources/resources/schemas/MOA-SPSS-3.1.2.xsd'
)
}
}
+war {
+ archiveBaseName.set("moa-spss")
+ duplicatesStrategy = DuplicatesStrategy.EXCLUDE
+}
+
distributions {
- main {
- distributionBaseName = "moa-spss"
- contents {
- into('/') { // Copy the following jars to the lib/ directory in the distribution archive
- from war.outputs
- from "$rootDir/../release-infos/readme_" + "$version" + ".txt"
- dirMode = 0755
- fileMode = 0644
- }
- into('/handbook') {
- from rootDir.toString() + "/../release-infos/handbook/"
- }
- into('/endorsed_libs') {
- from findJar('serializer')
- from findJar('xalan')
- from findJar('xercesImpl')
- from findJar('xml-apis')
- }
- into('/ext_libs') {
- from findJar('iaik_jce_full')
- from rootDir.toString() + "/../release-infos/ext_libs/"
-
- }
+ main {
+ distributionBaseName.set("moa-spss")
+ contents {
+ into('/') {
+ from(tasks.named('war'))
+ from("$rootDir/../release-infos/readme_${version}.txt")
+ dirMode = 0755
+ fileMode = 0644
+ }
+ into('/handbook') {
+ from("$rootDir/../release-infos/handbook")
+ }
+ into('/endorsed_libs') {
+ from(findJar('serializer'))
+ from(findJar('xalan'))
+ from(findJar('xercesImpl'))
+ from(findJar('xml-apis'))
+ }
+ into('/ext_libs') {
+ from(findJar('iaik_jce_full'))
+ from("$rootDir/../release-infos/ext_libs/")
+ }
+ }
}
- }
}
-def findJar(prefix) {
- configurations.runtimeClasspath.filter { it.name.startsWith(prefix) }
-
+def findJar(String prefix) {
+ return configurations.runtimeClasspath.filter { it.name.startsWith(prefix) }
}
-task releases(type: Copy) {
- from distZip.outputs
- //from distTar.outputs
- into rootDir.toString() + "/releases/" + version
+tasks.register('releases', Copy) {
+ dependsOn(tasks.named('distZip'))
+ from(tasks.named('distZip'))
+ into "$rootDir/releases/${version}"
}
--
cgit v1.2.3
From 773535ab90950460f468d2edfc5be396f2776d25 Mon Sep 17 00:00:00 2001
From: Thomas Lenz
Date: Wed, 6 Aug 2025 08:02:33 +0200
Subject: chore(core): refactor to Java 17 and Servlet-API 6.0
---
moaSig/build.gradle | 5 +++
moaSig/common/build.gradle | 23 +++++++---
.../gv/egovernment/moaspss/util/Base64Utils.java | 1 +
moaSig/moa-asic/build.gradle | 10 ++---
moaSig/moa-sig-lib/build.gradle | 49 +++++++++++----------
.../server/transaction/DeleteableDataSource.java | 2 +-
.../server/transaction/TransactionContext.java | 5 +--
moaSig/moa-sig/build.gradle | 34 +++++++++-----
moaSig/moa-sig/libs/activation-1.1.jar | Bin 62983 -> 0 bytes
moaSig/moa-sig/libs/axis-1.0_IAIK_1.3.jar | Bin 1096138 -> 0 bytes
moaSig/moa-sig/libs/axis-1.0_IAIK_1.4.jar | Bin 0 -> 1045637 bytes
.../moa-sig/libs/jakarta.activation-api-2.1.3.jar | Bin 0 -> 66514 bytes
moaSig/moa-sig/libs/jakarta.mail-api-2.1.3.jar | Bin 0 -> 236454 bytes
moaSig/moa-sig/libs/mail-1.4.jar | Bin 388826 -> 0 bytes
.../moa/spss/server/service/AxisHandler.java | 11 +++--
.../server/service/CertificateProviderServlet.java | 13 +++---
.../spss/server/service/ConfigurationServlet.java | 11 +++--
.../server/service/SignatureCreationService.java | 4 +-
.../server/service/TSLClientStatusServlet.java | 11 +++--
.../spss/server/utils/DataHandlerConverter.java | 49 +++++++++++++++++++++
.../moa/spss/server/utils/LoggerUtils.java | 41 +++++++++++++++++
.../webservice/SignatureCreationService.java | 8 ++--
.../webservice/SignatureVerificationService.java | 6 +--
moaSig/moa-sig/src/main/resources/logback.xml | 4 +-
.../test/integration/CadesIntegrationTest.java | 4 ++
25 files changed, 207 insertions(+), 84 deletions(-)
delete mode 100644 moaSig/moa-sig/libs/activation-1.1.jar
delete mode 100644 moaSig/moa-sig/libs/axis-1.0_IAIK_1.3.jar
create mode 100644 moaSig/moa-sig/libs/axis-1.0_IAIK_1.4.jar
create mode 100644 moaSig/moa-sig/libs/jakarta.activation-api-2.1.3.jar
create mode 100644 moaSig/moa-sig/libs/jakarta.mail-api-2.1.3.jar
delete mode 100644 moaSig/moa-sig/libs/mail-1.4.jar
create mode 100644 moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/DataHandlerConverter.java
create mode 100644 moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/LoggerUtils.java
(limited to 'moaSig/common')
diff --git a/moaSig/build.gradle b/moaSig/build.gradle
index 3dc1893..ddfa15f 100644
--- a/moaSig/build.gradle
+++ b/moaSig/build.gradle
@@ -25,12 +25,17 @@ allprojects {
}
}
+configurations.all {
+ exclude group: 'xml-apis', module: 'xml-apis'
+}
+
subprojects {
apply plugin: 'java-library'
apply plugin: 'eclipse'
apply plugin: 'maven-publish'
dependencies {
+ implementation("org.projectlombok:lombok:1.18.38")
testImplementation 'junit:junit:4.13.2'
}
diff --git a/moaSig/common/build.gradle b/moaSig/common/build.gradle
index 6054eff..79f1b02 100644
--- a/moaSig/common/build.gradle
+++ b/moaSig/common/build.gradle
@@ -5,14 +5,25 @@ plugins {
dependencies {
implementation files('../libs/iaik_jce_full_signed-6.1_moa.jar')
- api 'org.slf4j:slf4j-api:1.7.36'
- api 'xerces:xercesImpl:2.12.2'
- api 'xalan:xalan:2.7.1'
- api 'xalan:serializer:2.7.1'
- api 'joda-time:joda-time:2.12.7'
- api 'jaxen:jaxen:1.2.0'
+ api 'org.slf4j:slf4j-api:2.0.17'
+
+ api(group: 'xerces', name: 'xercesImpl', version: '2.12.2') {
+ exclude group: 'xml-apis', module: 'xml-apis'
+ }
+
+ api(group: 'xalan', name: 'xalan', version: '2.7.1') {
+ exclude group: 'xml-apis', module: 'xml-apis'
+ }
+
+ api(group: 'xalan', name: 'serializer', version: '2.7.1') {
+ exclude group: 'xml-apis', module: 'xml-apis'
+ }
+
+ api 'joda-time:joda-time:2.14.0'
+ api 'jaxen:jaxen:2.0.0'
}
+
java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
diff --git a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/Base64Utils.java b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/Base64Utils.java
index 2c9b4c0..a95ee5b 100644
--- a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/Base64Utils.java
+++ b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/Base64Utils.java
@@ -46,6 +46,7 @@ public class Base64Utils {
* @param base64String The String containing the Base64
* encoded bytes.
* @param ignoreInvalidChars Whether to ignore invalid Base64 characters.
+ * @param encoding Char encoding that should be used
* @return byte[] The raw bytes contained in the base64String.
* @throws IOException Failed to read the Base64 data.
*/
diff --git a/moaSig/moa-asic/build.gradle b/moaSig/moa-asic/build.gradle
index b2b7299..a132b05 100644
--- a/moaSig/moa-asic/build.gradle
+++ b/moaSig/moa-asic/build.gradle
@@ -19,15 +19,15 @@ configurations {
}
dependencies {
- jaxb 'com.sun.xml.bind:jaxb-xjc:3.0.2'
- jaxb 'org.glassfish.jaxb:jaxb-runtime:3.0.2'
+ jaxb 'com.sun.xml.bind:jaxb-xjc:4.0.5'
+ jaxb 'org.glassfish.jaxb:jaxb-runtime:4.0.5'
implementation project(':common')
implementation project(':moa-sig-lib')
- api 'jakarta.xml.bind:jakarta.xml.bind-api:3.0.1'
- api 'jakarta.xml.ws:jakarta.xml.ws-api:3.0.1'
- implementation 'org.slf4j:log4j-over-slf4j:1.7.36'
+ api 'jakarta.xml.bind:jakarta.xml.bind-api:4.0.2'
+ api 'jakarta.xml.ws:jakarta.xml.ws-api:4.0.2'
+ implementation 'org.slf4j:slf4j-api:2.0.17'
}
sourceSets {
diff --git a/moaSig/moa-sig-lib/build.gradle b/moaSig/moa-sig-lib/build.gradle
index ee46ed9..dd3a191 100644
--- a/moaSig/moa-sig-lib/build.gradle
+++ b/moaSig/moa-sig-lib/build.gradle
@@ -17,36 +17,37 @@ distributions {
dependencies {
implementation project(':common')
- testImplementation project(path: ':common', configuration: 'testArtifacts')
api fileTree(dir: '../libs', include: ['*.jar'])
// api fileTree(dir: '../libs_debug', include: ['*.jar'])
api 'at.gv.egovernment.moa.sig:tsl-lib:2.2.0-SNAPSHOT'
- api 'commons-logging:commons-logging:1.2'
- api 'commons-io:commons-io:2.16.1'
- api 'commons-codec:commons-codec:1.16.0'
+ api 'commons-logging:commons-logging:1.3.5'
+ api 'commons-io:commons-io:2.20.0'
+ api 'commons-codec:commons-codec:1.19.0'
api 'org.apache.axis:axis-jaxrpc:1.4'
- api 'org.xerial:sqlite-jdbc:3.46.1.0'
- api 'javax.activation:activation:1.1.1'
- api 'jakarta.xml.bind:jakarta.xml.bind-api:3.0.1'
- api 'com.sun.xml.bind:jaxb-core:3.0.2'
- api 'com.sun.xml.bind:jaxb-impl:3.0.2'
- api 'org.postgresql:postgresql:42.7.1'
-
- api 'org.apache.pdfbox:pdfbox:2.0.32'
- api 'org.apache.pdfbox:pdfbox-tools:2.0.32'
- api 'org.apache.pdfbox:pdfbox-app:2.0.32'
- api 'org.apache.pdfbox:preflight:2.0.32'
- api 'org.apache.pdfbox:preflight-app:2.0.32'
- api 'org.apache.commons:commons-lang3:3.16.0'
- api 'org.apache.httpcomponents:httpclient-cache:4.5.14'
- api 'org.slf4j:jcl-over-slf4j:1.7.36'
-
- testImplementation 'org.junit.jupiter:junit-jupiter-migrationsupport:5.10.1'
- testImplementation 'org.junit.platform:junit-platform-engine:1.10.1'
- testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.1'
- testImplementation 'ch.qos.logback:logback-classic:1.2.13'
+ api 'org.xerial:sqlite-jdbc:3.50.3.0'
+ api 'jakarta.activation:jakarta.activation-api:2.1.3'
+ api 'jakarta.xml.bind:jakarta.xml.bind-api:4.0.2'
+ //api 'com.sun.xml.bind:jaxb-core:4.0.5'
+ api 'com.sun.xml.bind:jaxb-impl:4.0.5'
+ api 'org.postgresql:postgresql:42.7.7'
+
+ api 'org.apache.pdfbox:pdfbox:2.0.34'
+ api 'org.apache.pdfbox:pdfbox-tools:2.0.34'
+ api 'org.apache.pdfbox:pdfbox-app:2.0.34'
+ api 'org.apache.pdfbox:preflight:2.0.34'
+ api 'org.apache.pdfbox:preflight-app:2.0.34'
+ api 'org.apache.commons:commons-lang3:3.18.0'
+ api 'org.apache.httpcomponents.client5:httpclient5-cache:5.4.4'
+ api 'org.slf4j:jcl-over-slf4j:2.0.17'
+
+
+ testImplementation project(path: ':common', configuration: 'testArtifacts')
+ testImplementation 'org.junit.jupiter:junit-jupiter-migrationsupport:5.13.4'
+ //testImplementation 'org.junit.platform:junit-platform-engine:1.13.4'
+ testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.13.4'
+ testImplementation 'ch.qos.logback:logback-classic:1.5.18'
}
tasks.register('releases', Copy) {
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/DeleteableDataSource.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/DeleteableDataSource.java
index 335bf68..a60590d 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/DeleteableDataSource.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/DeleteableDataSource.java
@@ -1,6 +1,6 @@
package at.gv.egovernment.moa.spss.server.transaction;
-import javax.activation.DataSource;
+import jakarta.activation.DataSource;
public interface DeleteableDataSource extends DataSource {
void delete();
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/TransactionContext.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/TransactionContext.java
index 5746657..06326a0 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/TransactionContext.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/transaction/TransactionContext.java
@@ -33,14 +33,13 @@ import java.util.Iterator;
import java.util.Map.Entry;
import java.util.Vector;
-import javax.activation.DataSource;
-
import org.w3c.dom.Element;
import at.gv.egovernment.moa.spss.MOAApplicationException;
import at.gv.egovernment.moa.spss.server.config.ConfigurationProvider;
import at.gv.egovernment.moaspss.logging.Logger;
import iaik.xml.crypto.utils.URI;
+import jakarta.activation.DataSource;
/**
* Contains information about the current request.
@@ -310,7 +309,7 @@ public class TransactionContext {
}
// not available in Axis 1.0 to 1.1
// File f = mmds.getDiskCacheFile();
-// if (f!=null) f.delete();
+// if (f!=null) f.delete();
if (mmds instanceof DeleteableDataSource) {
((DeleteableDataSource) mmds).delete();
}
diff --git a/moaSig/moa-sig/build.gradle b/moaSig/moa-sig/build.gradle
index eba2e76..edd6aa0 100644
--- a/moaSig/moa-sig/build.gradle
+++ b/moaSig/moa-sig/build.gradle
@@ -17,24 +17,34 @@ configurations {
}
dependencies {
- jaxb 'com.sun.xml.bind:jaxb-xjc:3.0.2'
- jaxb 'org.glassfish.jaxb:jaxb-runtime:3.0.2'
+ jaxb 'com.sun.xml.bind:jaxb-xjc:4.0.5'
+ jaxb 'org.glassfish.jaxb:jaxb-runtime:4.0.5'
- implementation project(':common')
+ implementation project(':common')
implementation project(':moa-sig-lib')
implementation project(':moa-asic')
implementation fileTree(dir: 'libs', include: ['*.jar'])
- compileOnly 'javax.servlet:javax.servlet-api:3.1.0'
+ compileOnly 'jakarta.servlet:jakarta.servlet-api:6.0.0'
implementation 'commons-discovery:commons-discovery:0.5'
- implementation 'org.apache.logging.log4j:log4j-1.2-api:2.22.1'
- implementation 'org.slf4j:log4j-over-slf4j:1.7.36'
- implementation 'javax.jws:javax.jws-api:1.1'
- implementation 'ch.qos.logback:logback-classic:1.2.13'
+ implementation 'org.apache.logging.log4j:log4j-1.2-api:2.25.1'
+ implementation 'org.slf4j:log4j-over-slf4j:2.0.17'
+ implementation 'jakarta.jws:jakarta.jws-api:3.0.0'
+ implementation 'jakarta.xml.bind:jakarta.xml.bind-api:4.0.2'
+ implementation 'ch.qos.logback:logback-classic:1.5.18'
- testImplementation 'org.junit.jupiter:junit-jupiter-migrationsupport:5.10.1'
- testImplementation 'org.junit.platform:junit-platform-engine:1.10.1'
- testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.1'
- testImplementation 'ch.qos.logback:logback-classic:1.2.13'
+ implementation("javax.activation:activation:1.1.1")
+ implementation("org.eclipse.angus:angus-mail:2.0.4")
+
+ testImplementation 'org.junit.jupiter:junit-jupiter-migrationsupport:5.13.4'
+ //testImplementation 'org.junit.platform:junit-platform-engine:1.13.4'
+ testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.13.4'
+ testImplementation 'ch.qos.logback:logback-classic:1.5.18'
+
+ testImplementation project(':common')
+ testImplementation project(path: ':common', configuration: 'testArtifacts')
+ testImplementation project(':moa-sig-lib')
+ testImplementation project(':moa-asic')
+
}
sourceSets {
diff --git a/moaSig/moa-sig/libs/activation-1.1.jar b/moaSig/moa-sig/libs/activation-1.1.jar
deleted file mode 100644
index 53f82a1..0000000
Binary files a/moaSig/moa-sig/libs/activation-1.1.jar and /dev/null differ
diff --git a/moaSig/moa-sig/libs/axis-1.0_IAIK_1.3.jar b/moaSig/moa-sig/libs/axis-1.0_IAIK_1.3.jar
deleted file mode 100644
index 81103be..0000000
Binary files a/moaSig/moa-sig/libs/axis-1.0_IAIK_1.3.jar and /dev/null differ
diff --git a/moaSig/moa-sig/libs/axis-1.0_IAIK_1.4.jar b/moaSig/moa-sig/libs/axis-1.0_IAIK_1.4.jar
new file mode 100644
index 0000000..0935d37
Binary files /dev/null and b/moaSig/moa-sig/libs/axis-1.0_IAIK_1.4.jar differ
diff --git a/moaSig/moa-sig/libs/jakarta.activation-api-2.1.3.jar b/moaSig/moa-sig/libs/jakarta.activation-api-2.1.3.jar
new file mode 100644
index 0000000..0d015d5
Binary files /dev/null and b/moaSig/moa-sig/libs/jakarta.activation-api-2.1.3.jar differ
diff --git a/moaSig/moa-sig/libs/jakarta.mail-api-2.1.3.jar b/moaSig/moa-sig/libs/jakarta.mail-api-2.1.3.jar
new file mode 100644
index 0000000..6b36779
Binary files /dev/null and b/moaSig/moa-sig/libs/jakarta.mail-api-2.1.3.jar differ
diff --git a/moaSig/moa-sig/libs/mail-1.4.jar b/moaSig/moa-sig/libs/mail-1.4.jar
deleted file mode 100644
index 3b28b6e..0000000
Binary files a/moaSig/moa-sig/libs/mail-1.4.jar and /dev/null differ
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/AxisHandler.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/AxisHandler.java
index 8c220ee..f206167 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/AxisHandler.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/AxisHandler.java
@@ -33,8 +33,6 @@ import java.security.cert.X509Certificate;
import java.util.Enumeration;
import java.util.Iterator;
-import javax.servlet.http.HttpServletRequest;
-
import org.apache.axis.AxisFault;
import org.apache.axis.Message;
import org.apache.axis.MessageContext;
@@ -53,12 +51,15 @@ import at.gv.egovernment.moa.spss.server.config.ConfigurationProvider;
import at.gv.egovernment.moa.spss.server.transaction.TransactionContext;
import at.gv.egovernment.moa.spss.server.transaction.TransactionContextManager;
import at.gv.egovernment.moa.spss.server.transaction.TransactionIDGenerator;
+import at.gv.egovernment.moa.spss.server.utils.DataHandlerConverter;
import at.gv.egovernment.moa.spss.util.MessageProvider;
import at.gv.egovernment.moaspss.logging.LogMsg;
import at.gv.egovernment.moaspss.logging.Logger;
import at.gv.egovernment.moaspss.logging.LoggingContext;
import at.gv.egovernment.moaspss.logging.LoggingContextManager;
import at.gv.egovernment.moaspss.util.DOMUtils;
+import jakarta.activation.DataHandler;
+import jakarta.servlet.http.HttpServletRequest;
/**
* An handler that is invoked on each web service request and performs some
@@ -202,7 +203,11 @@ public class AxisHandler extends BasicHandler {
// content with Object content =
// attachment.getContent();)
InputStream is = null;
- final javax.activation.DataHandler datahandler = attachment.getDataHandler();
+
+ Object dataHandlerObj = attachment.getDataHandler();
+ final DataHandler datahandler = dataHandlerObj instanceof DataHandler
+ ? (DataHandler) dataHandlerObj
+ : DataHandlerConverter.convert((javax.activation.DataHandler) dataHandlerObj);
final int TYPE = 2;
switch (TYPE) {
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/CertificateProviderServlet.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/CertificateProviderServlet.java
index bc2c3b6..dee5d90 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/CertificateProviderServlet.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/CertificateProviderServlet.java
@@ -11,11 +11,6 @@ import java.util.Iterator;
import java.util.List;
import java.util.Set;
-import javax.servlet.ServletException;
-import javax.servlet.http.HttpServlet;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
import at.gv.egovernment.moa.spss.server.config.ConfigurationException;
import at.gv.egovernment.moa.spss.server.config.ConfigurationProvider;
import at.gv.egovernment.moa.spss.server.config.KeyGroupEntry;
@@ -25,6 +20,10 @@ import at.gv.egovernment.moaspss.logging.Logger;
import iaik.server.modules.keys.KeyEntryID;
import iaik.server.modules.keys.KeyModule;
import iaik.server.modules.keys.KeyModuleFactory;
+import jakarta.servlet.ServletException;
+import jakarta.servlet.http.HttpServlet;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
/**
*
@@ -34,7 +33,7 @@ import iaik.server.modules.keys.KeyModuleFactory;
public class CertificateProviderServlet extends HttpServlet {
/**
- *
+ *
*/
private static final long serialVersionUID = -6907582473072190122L;
@@ -46,7 +45,7 @@ public class CertificateProviderServlet extends HttpServlet {
/**
* Build the set of KeyEntryIDs available to the given
* keyGroupID.
- *
+ *
* @param keyGroupID The keygroup ID for which the available keys should be
* returned.
* @return The Set of KeyEntryIDs identifying the
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java
index 135d652..6127305 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java
@@ -29,11 +29,6 @@ import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
-import javax.servlet.ServletException;
-import javax.servlet.http.HttpServlet;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
import at.gv.egovernment.moa.spss.server.config.ConfigurationProvider;
import at.gv.egovernment.moa.spss.server.iaik.config.IaikConfigurator;
import at.gv.egovernment.moa.spss.server.init.SystemInitializer;
@@ -42,6 +37,10 @@ import at.gv.egovernment.moaspss.logging.LogMsg;
import at.gv.egovernment.moaspss.logging.Logger;
import at.gv.egovernment.moaspss.logging.LoggingContext;
import at.gv.egovernment.moaspss.logging.LoggingContextManager;
+import jakarta.servlet.ServletException;
+import jakarta.servlet.http.HttpServlet;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
/**
* A servlet to initialize and update the MOA configuration.
@@ -52,7 +51,7 @@ import at.gv.egovernment.moaspss.logging.LoggingContextManager;
*/
public class ConfigurationServlet extends HttpServlet {
/**
- *
+ *
*/
private static final long serialVersionUID = 8372961105222028696L;
/** The document type of the HTML to generate. */
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/SignatureCreationService.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/SignatureCreationService.java
index 4030883..7973e44 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/SignatureCreationService.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/SignatureCreationService.java
@@ -63,7 +63,7 @@ public class SignatureCreationService {
/**
* Handle a CreatePDFSignatureRequest.
- *
+ *
* @param request The CreatePDFSignatureRequest to work on
* (contained in the 0th element of the array).
* @return A CreatePDFSignatureResponse as the only element of the
@@ -152,7 +152,7 @@ public class SignatureCreationService {
/**
* Handle a CreateXMLSignatureRequest.
- *
+ *
* @param request The CreateXMLSignatureRequest to work on
* (contained in the 0th element of the array).
* @return A CreateXMLSignatureResponse as the only element of the
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/TSLClientStatusServlet.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/TSLClientStatusServlet.java
index 3bf9a37..abdf121 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/TSLClientStatusServlet.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/TSLClientStatusServlet.java
@@ -5,18 +5,17 @@ import java.io.PrintWriter;
import java.text.MessageFormat;
import java.util.List;
-import javax.servlet.ServletException;
-import javax.servlet.http.HttpServlet;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
import at.gv.egovernment.moa.sig.tsl.engine.data.TSLProcessingResultElement;
import at.gv.egovernment.moa.spss.server.monitoring.ServiceStatusContainer;
+import jakarta.servlet.ServletException;
+import jakarta.servlet.http.HttpServlet;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
public class TSLClientStatusServlet extends HttpServlet {
/**
- *
+ *
*/
private static final long serialVersionUID = 1L;
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/DataHandlerConverter.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/DataHandlerConverter.java
new file mode 100644
index 0000000..fd11789
--- /dev/null
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/DataHandlerConverter.java
@@ -0,0 +1,49 @@
+package at.gv.egovernment.moa.spss.server.utils;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+
+import lombok.experimental.UtilityClass;
+
+/**
+ * Utility to convert javax.activation.DataHandler to jakarta.activation.DataHandler.
+ */
+@UtilityClass
+public class DataHandlerConverter {
+
+ /**
+ * Converts javax.activation.DataHandler to jakarta.activation.DataHandler
+ */
+ public static jakarta.activation.DataHandler convert(javax.activation.DataHandler oldHandler) {
+ if (oldHandler == null) return null;
+
+ javax.activation.DataSource oldSource = oldHandler.getDataSource();
+
+ // Wrap the old javax.activation.DataSource in a jakarta.activation.DataSource
+ jakarta.activation.DataSource newSource = new jakarta.activation.DataSource() {
+ @Override
+ public InputStream getInputStream() throws IOException {
+ return oldSource.getInputStream();
+ }
+
+ @Override
+ public OutputStream getOutputStream() throws IOException {
+ return oldSource.getOutputStream();
+ }
+
+ @Override
+ public String getContentType() {
+ return oldSource.getContentType();
+ }
+
+ @Override
+ public String getName() {
+ return oldSource.getName();
+ }
+ };
+
+ return new jakarta.activation.DataHandler(newSource);
+ }
+}
+
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/LoggerUtils.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/LoggerUtils.java
new file mode 100644
index 0000000..78d5039
--- /dev/null
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/utils/LoggerUtils.java
@@ -0,0 +1,41 @@
+package at.gv.egovernment.moa.spss.server.utils;
+
+import java.util.Properties;
+
+import iaik.logging.LogConfigurationException;
+import iaik.logging.LogFactory;
+import iaik.logging.LoggerConfig;
+import lombok.experimental.UtilityClass;
+
+/**
+ * Logging helper.
+ */
+@UtilityClass
+public class LoggerUtils {
+
+ /**
+ * Fix {@link iaik.logging.impl.LogSlf4jFactoryImpl}, because it uses
+ * org.slf4j.impl.StaticLoggerBinder which was removed since v
+ * 1.5.x.
+ */
+ public static void fixLoggerFactory() {
+ LogFactory.configure(new LoggerConfig() {
+
+ @Override
+ public Properties getProperties() throws LogConfigurationException {
+ return null;
+ }
+
+ @Override
+ public String getNodeId() {
+ return null;
+ }
+
+ @Override
+ public String getFactory() {
+ return "iaik.logging.impl.OwnLogSlf4jFactoryImpl";
+ }
+ });
+ }
+
+}
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureCreationService.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureCreationService.java
index bf06ff6..4b91ec1 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureCreationService.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureCreationService.java
@@ -1,8 +1,8 @@
package at.gv.egovernment.moa.spss.server.webservice;
-import javax.jws.WebMethod;
-import javax.jws.WebParam;
-import javax.jws.WebService;
+import jakarta.jws.WebMethod;
+import jakarta.jws.WebParam;
+import jakarta.jws.WebService;
@WebService(name = "SignatureCreationService",
targetNamespace = "http://reference.e-government.gv.at/namespace/moa/20151109#")
@@ -24,7 +24,7 @@ public interface SignatureCreationService {
* @WebMethod(action = "PDFSignatureCreate", operationName =
* "PDFSignatureCreate") public at.gv.egiz.moasig.CreatePDFSignatureResponseType
* createPDFSignature(
- *
+ *
* @WebParam(name = "CreatePDFSignatureRequest")
* at.gv.egiz.moasig.CreatePDFSignatureRequest createPDFSignatureRequest) throws
* Exception;
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureVerificationService.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureVerificationService.java
index ca30650..d8aa9b6 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureVerificationService.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/webservice/SignatureVerificationService.java
@@ -1,8 +1,8 @@
package at.gv.egovernment.moa.spss.server.webservice;
-import javax.jws.WebMethod;
-import javax.jws.WebParam;
-import javax.jws.WebService;
+import jakarta.jws.WebMethod;
+import jakarta.jws.WebParam;
+import jakarta.jws.WebService;
@WebService(name = "SignatureVerificationService",
targetNamespace = "http://reference.e-government.gv.at/namespace/moa/20151109#")
diff --git a/moaSig/moa-sig/src/main/resources/logback.xml b/moaSig/moa-sig/src/main/resources/logback.xml
index 0012e81..0afb5cc 100644
--- a/moaSig/moa-sig/src/main/resources/logback.xml
+++ b/moaSig/moa-sig/src/main/resources/logback.xml
@@ -12,7 +12,7 @@
${catalina.base}/logs/moa-spss.log
- logback | %5p | %d{dd HH:mm:ss,SSS} | %C{1} | %20c | %10t | %m%n
+ %5p | %d{dd HH:mm:ss.SSS} | %C{1} | %20c | %10t | %m%n
10
@@ -24,7 +24,7 @@
- logback | %5p | %d{dd HH:mm:ss,SSS} | %C{1} | %20c | %10t | %m%n
+ %5p | %d{dd HH:mm:ss.SSS} | %C{1} | %20c | %10t | %m%n
diff --git a/moaSig/moa-sig/src/test/java/at/gv/egovernment/moa/spss/test/integration/CadesIntegrationTest.java b/moaSig/moa-sig/src/test/java/at/gv/egovernment/moa/spss/test/integration/CadesIntegrationTest.java
index 191bed9..a88873a 100644
--- a/moaSig/moa-sig/src/test/java/at/gv/egovernment/moa/spss/test/integration/CadesIntegrationTest.java
+++ b/moaSig/moa-sig/src/test/java/at/gv/egovernment/moa/spss/test/integration/CadesIntegrationTest.java
@@ -38,6 +38,7 @@ import at.gv.egovernment.moa.spss.server.config.ConfigurationProvider;
import at.gv.egovernment.moa.spss.server.init.SystemInitializer;
import at.gv.egovernment.moa.spss.server.invoke.CMSSignatureCreationInvoker;
import at.gv.egovernment.moa.spss.server.invoke.CMSSignatureVerificationInvoker;
+import at.gv.egovernment.moa.spss.server.utils.LoggerUtils;
import at.gv.egovernment.moa.spss.tsl.TSLServiceFactory;
import at.gv.egovernment.moaspss.util.DOMUtils;
import iaik.pki.Configurator;
@@ -52,6 +53,9 @@ public class CadesIntegrationTest extends AbstractIntegrationTest {
@BeforeClass
public static void classInitializer() throws IOException, ConfigurationException,
NoSuchFieldException, SecurityException, IllegalArgumentException, IllegalAccessException {
+
+ LoggerUtils.fixLoggerFactory();
+
jvmStateReset();
final String current = new java.io.File(".").getCanonicalPath();
--
cgit v1.2.3
From 3776bd908568cf4612fa80e1ab4b576a2585fbf7 Mon Sep 17 00:00:00 2001
From: Thomas Lenz
Date: Thu, 18 Sep 2025 09:07:19 +0200
Subject: chore(core): remove deprecated API calls and fix JavaDoc
---
.../at/gv/egovernment/moaspss/util/DOMUtils.java | 20 -------------
.../gv/egovernment/moaspss/util/KeyStoreUtils.java | 2 +-
.../egovernment/moaspss/util/MOAErrorHandler.java | 4 +--
.../at/gv/egovernment/moaspss/util/MOATimer.java | 4 +--
.../VerifyASICSignatureResponseBuilder.java | 3 +-
.../gv/egovernment/moa/spss/api/SPSSFactory.java | 13 ++++-----
...ateSignatureEnvironmentProfileExplicitImpl.java | 2 +-
.../spss/api/impl/VerifyTransformsDataImpl.java | 2 +-
.../moa/spss/api/xmlbind/RequestParserUtils.java | 19 +++++++------
.../moa/spss/api/xmlbind/ResponseBuilderUtils.java | 2 +-
.../xmlbind/VerifyCMSSignatureRequestParser.java | 2 +-
.../spss/server/config/CRLDistributionPoint.java | 33 +++++++++++-----------
.../server/config/ConfigurationPartsBuilder.java | 12 ++++----
.../cmssign/CMSSignatureCreationProfileImpl.java | 19 +++++++++----
.../moa/spss/server/iaik/config/CRLRetriever.java | 1 -
.../iaik/config/DataBaseArchiveParameterImpl.java | 4 ---
.../store/truststore/TrustStoreProfileImpl.java | 7 ++---
.../invoke/CMSSignatureVerificationInvoker.java | 2 +-
.../invoke/CreateCMSSignatureResponseBuilder.java | 14 ++++-----
.../invoke/VerifyCMSSignatureResponseBuilder.java | 31 +++++++++++++-------
.../invoke/VerifyXMLSignatureResponseBuilder.java | 2 +-
.../invoke/XMLSignatureVerificationInvoker.java | 6 ++--
.../egovernment/moa/spss/util/AdESResultUtils.java | 10 +++----
.../moa/spss/util/ExternalURIVerifier.java | 4 +--
.../spss/server/service/ConfigurationServlet.java | 6 ----
25 files changed, 105 insertions(+), 119 deletions(-)
(limited to 'moaSig/common')
diff --git a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/DOMUtils.java b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/DOMUtils.java
index 2f96196..86d2e54 100644
--- a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/DOMUtils.java
+++ b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/DOMUtils.java
@@ -315,26 +315,6 @@ public class DOMUtils {
*
* @param inputStream The InputStream
* containing the XML document.
- * @param validating If true, parse
- * validating.
- * @param externalSchemaLocations A String containing
- * namespace URI to schema location
- * pairs, the same way it is accepted
- * by the xsi:
- * schemaLocation attribute.
- * @param externalNoNamespaceSchemaLocation The schema location of the schema
- * for elements without a namespace,
- * the same way it is accepted by the
- * xsi:noNamespaceSchemaLocation
- * attribute.
- * @param entityResolver An EntityResolver to
- * resolve external entities (schemas
- * and DTDs). If null, it
- * will not be set.
- * @param errorHandler An ErrorHandler to
- * decide what to do with parsing
- * errors. If null, it
- * will not be set.
* @return The parsed XML document as a DOM tree.
* @throws SAXException An error occurred parsing the document.
* @throws IOException An error occurred reading the document.
diff --git a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/KeyStoreUtils.java b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/KeyStoreUtils.java
index f62b82a..94ecc8b 100644
--- a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/KeyStoreUtils.java
+++ b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/KeyStoreUtils.java
@@ -202,7 +202,7 @@ public class KeyStoreUtils {
/**
* Loads a keyStore without knowing the keyStore type
*
- * @param in input stream
+ * @param is input stream
* @param password Password protecting the keyStore
* @return keyStore loaded
* @throws KeyStoreException thrown if keyStore cannot be loaded
diff --git a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOAErrorHandler.java b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOAErrorHandler.java
index f4acabf..2ab55a2 100644
--- a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOAErrorHandler.java
+++ b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOAErrorHandler.java
@@ -113,8 +113,8 @@ public class MOAErrorHandler extends DefaultErrorHandler {
return new Object[] {
e.getMessage(),
e.getSystemId(),
- new Integer(e.getLineNumber()),
- new Integer(e.getColumnNumber()) };
+ Integer.valueOf(e.getLineNumber()),
+ Integer.valueOf(e.getColumnNumber()) };
}
}
\ No newline at end of file
diff --git a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOATimer.java b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOATimer.java
index 591495a..13133ea 100644
--- a/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOATimer.java
+++ b/moaSig/common/src/main/java/at/gv/egovernment/moaspss/util/MOATimer.java
@@ -70,7 +70,7 @@ public class MOATimer {
* @param id The action ID.
*/
public void startTiming(Object id) {
- timemapstart.put(id, new Long(System.currentTimeMillis()));
+ timemapstart.put(id, Long.valueOf(System.currentTimeMillis()));
}
/**
@@ -79,7 +79,7 @@ public class MOATimer {
* @param id The action ID.
*/
public void stopTiming(Object id) {
- timemapend.put(id, new Long(System.currentTimeMillis()));
+ timemapend.put(id, Long.valueOf(System.currentTimeMillis()));
}
/**
diff --git a/moaSig/moa-asic/src/main/java/at/gv/egiz/asic/xmlbind/VerifyASICSignatureResponseBuilder.java b/moaSig/moa-asic/src/main/java/at/gv/egiz/asic/xmlbind/VerifyASICSignatureResponseBuilder.java
index 34744ef..02fbeb2 100644
--- a/moaSig/moa-asic/src/main/java/at/gv/egiz/asic/xmlbind/VerifyASICSignatureResponseBuilder.java
+++ b/moaSig/moa-asic/src/main/java/at/gv/egiz/asic/xmlbind/VerifyASICSignatureResponseBuilder.java
@@ -74,8 +74,7 @@ public class VerifyASICSignatureResponseBuilder {
* element being the XML representation of the given
* VerifyCMSSignatureResponse API object.
*
- * @param response The VerifyCMSSignatureResponse to convert to
- * XML.
+ * @param results The VerifyCMSSignatureResponse to convert to XML.
* @return A document containing the VerifyCMSSignatureResponse DOM
* element.
* @throws MOAApplicationException An error occurred building the response.
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/SPSSFactory.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/SPSSFactory.java
index d0be7d5..5d378ce 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/SPSSFactory.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/SPSSFactory.java
@@ -316,7 +316,7 @@ public abstract class SPSSFactory {
* @param profileID The profile ID to resolve during signature creation.
* @return The CreateSignatureEnvironmentProfile containing the
* given profile ID.
- *
+ *
* @pre profileID != null && profileID.length() > 0
* @post return != null
*/
@@ -398,8 +398,7 @@ public abstract class SPSSFactory {
/**
* Create a new SignatureEnvironmentResponse object.
*
- * @param signatureEnvironment The signature environment containing the
- * signature.
+ * @param base64value Signature as Base64 encoded data
* @return The SignatureEnvironmentResponse containing the
* signatureEnvironment.
*
@@ -959,15 +958,15 @@ public abstract class SPSSFactory {
/**
* Create a new Content object containing location reference data.
- *
+ *
* @param locationReferenceURI a URI pointing to the actual remote location of
* the content.
- *
+ *
* @param referenceURI An URI identifying the data. May be
* null.
- *
+ *
* @return The Content object containing the data.
- *
+ *
* @pre locationReferenceURI != null
* @post return != null
*/
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/CreateSignatureEnvironmentProfileExplicitImpl.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/CreateSignatureEnvironmentProfileExplicitImpl.java
index 3d5279f..ab73c22 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/CreateSignatureEnvironmentProfileExplicitImpl.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/CreateSignatureEnvironmentProfileExplicitImpl.java
@@ -32,7 +32,7 @@ import at.gv.egovernment.moa.spss.api.xmlsign.CreateSignatureLocation;
/**
* Default implementation of
- * .
+ * CreateSignatureEnvironmentProfileExplicit.
*
* @author Patrick Peck
* @version $Id$
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/VerifyTransformsDataImpl.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/VerifyTransformsDataImpl.java
index d1eebca..ed6f449 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/VerifyTransformsDataImpl.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/impl/VerifyTransformsDataImpl.java
@@ -30,7 +30,7 @@ import java.util.List;
import at.gv.egovernment.moa.spss.api.xmlverify.ReferenceInfo;
/**
- * Default implementation of .
+ * Default implementation of ReferenceInfo.
*
* @author Fatemeh Philippi
* @version $Id$
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/RequestParserUtils.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/RequestParserUtils.java
index 173ecbf..571977e 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/RequestParserUtils.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/RequestParserUtils.java
@@ -62,7 +62,7 @@ public class RequestParserUtils {
/**
* Parse a XMLDataObjectAssociationType kind of DOM element.
- *
+ *
* @param assocElem The XMLDataObjectAssociationType kind of DOM
* elmeent to parse.
* @return The XMLDataObjectAssociation API object containing the
@@ -79,7 +79,7 @@ public class RequestParserUtils {
/**
* Parse a MetaInfoType kind of DOM element.
- *
+ *
* @param metaInfoElem The MetaInfoType kind of DOM element.
* @return The MetaInfo API object containing the data from the
* metaInfoElem.
@@ -97,7 +97,7 @@ public class RequestParserUtils {
/**
* Parse a ContentOptionalRefType or
* ContentRequiredRefType kind of DOM element.
- *
+ *
* @param contentParentElem The DOM element being the parent of the content
* element.
* @return The Content API object containing the data from the
@@ -127,7 +127,7 @@ public class RequestParserUtils {
/**
* Get the signing time from a Verfiy(CMS|XML)SignatureRequest.
- *
+ *
* @param requestElem A Verify(CMS|XML)SignatureRequest DOM
* element.
* @param dateTimeXPath The XPath to lookup the DateTime element
@@ -162,11 +162,12 @@ public class RequestParserUtils {
/**
* Get the signing time from a Verfiy(CMS|XML)SignatureRequest.
- *
- * @param requestElem A Verify(CMS|XML)SignatureRequest DOM
- * element.
- * @param dateTimeXPath The XPath to lookup the DateTime element
- * within the request.
+ *
+ * @param requestElem A Verify(CMS|XML)SignatureRequest
+ * DOM element.
+ * @param extendedValidationXPath The XPath to lookup the DateTime
+ * element within the request.
+ * @param defaultValue Default value if XPath value is null or empty
* @return Date The date and time corresponding to the DateTime
* element in the request. If no DateTime element exists in
* the request, null is returned.
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/ResponseBuilderUtils.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/ResponseBuilderUtils.java
index 1156aa1..daf3802 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/ResponseBuilderUtils.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/ResponseBuilderUtils.java
@@ -499,7 +499,7 @@ public class ResponseBuilderUtils {
* element.
* @param elementName The name of the newly created element.
* @param code The content of the Code subelement.
- * @param info The content of the Info subelement.
+ * @param name The content of the Info subelement.
*/
public static void addFormCheckElement(
Document response,
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureRequestParser.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureRequestParser.java
index bcab978..1279d73 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureRequestParser.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureRequestParser.java
@@ -171,7 +171,7 @@ public class VerifyCMSSignatureRequestParser {
// put the signatories into a List
while (tokenizer.hasMoreTokens()) {
try {
- signatoriesList.add(new Integer(tokenizer.nextToken()));
+ signatoriesList.add(Integer.valueOf(tokenizer.nextToken()));
} catch (final NumberFormatException e) {
// this cannot occur if the request has been validated
}
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/CRLDistributionPoint.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/CRLDistributionPoint.java
index bf11240..0f1a57d 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/CRLDistributionPoint.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/CRLDistributionPoint.java
@@ -50,18 +50,19 @@ public class CRLDistributionPoint extends DistributionPoint implements
// create the mapping between reason code strings and their integer
// values
- RC_MAPPING.put("unused", new Integer(iaik.asn1.structures.DistributionPoint.unused));
- RC_MAPPING.put("keyCompromise", new Integer(iaik.asn1.structures.DistributionPoint.keyCompromise));
- RC_MAPPING.put("cACompromise", new Integer(iaik.asn1.structures.DistributionPoint.cACompromise));
- RC_MAPPING.put("affiliationChanged", new Integer(
+ RC_MAPPING.put("unused", Integer.valueOf(iaik.asn1.structures.DistributionPoint.unused));
+ RC_MAPPING.put("keyCompromise", Integer.valueOf(iaik.asn1.structures.DistributionPoint.keyCompromise));
+ RC_MAPPING.put("cACompromise", Integer.valueOf(iaik.asn1.structures.DistributionPoint.cACompromise));
+ RC_MAPPING.put("affiliationChanged", Integer.valueOf(
iaik.asn1.structures.DistributionPoint.affiliationChanged));
- RC_MAPPING.put("superseded", new Integer(iaik.asn1.structures.DistributionPoint.superseded));
+ RC_MAPPING.put("superseded", Integer.valueOf(iaik.asn1.structures.DistributionPoint.superseded));
RC_MAPPING.put("cessationOfOperation",
- new Integer(iaik.asn1.structures.DistributionPoint.cessationOfOperation));
- RC_MAPPING.put("certificateHold", new Integer(iaik.asn1.structures.DistributionPoint.certificateHold));
- RC_MAPPING.put("privilegeWithdrawn", new Integer(
+ Integer.valueOf(iaik.asn1.structures.DistributionPoint.cessationOfOperation));
+ RC_MAPPING.put("certificateHold", Integer.valueOf(
+ iaik.asn1.structures.DistributionPoint.certificateHold));
+ RC_MAPPING.put("privilegeWithdrawn", Integer.valueOf(
iaik.asn1.structures.DistributionPoint.privilegeWithdrawn));
- RC_MAPPING.put("aACompromise", new Integer(iaik.asn1.structures.DistributionPoint.aACompromise));
+ RC_MAPPING.put("aACompromise", Integer.valueOf(iaik.asn1.structures.DistributionPoint.aACompromise));
}
/**
@@ -76,12 +77,12 @@ public class CRLDistributionPoint extends DistributionPoint implements
/**
* Create a CRLDistributionPoint.
- *
+ *
* @param issuerName The name of the CA issuing the CRL referred to by this
* DP.
- *
+ *
* @param uri The URI of the distribution point.
- *
+ *
* @param reasonCodeStr A list of reason codes (a space-separated enumeration).
*/
public CRLDistributionPoint(String issuerName, String uri, String reasonCodeStr) {
@@ -101,7 +102,7 @@ public class CRLDistributionPoint extends DistributionPoint implements
/**
* Convert a list of reason codes provided as a String to a binary
* representation.
- *
+ *
* @param reasonCodeStr A String containing a blank-separated,
* textual representation of reason codes.
* @return int A binary representation of reason codes.
@@ -143,7 +144,7 @@ public class CRLDistributionPoint extends DistributionPoint implements
/**
* Return a binary representation of the reason codes of this distribution
* point.
- *
+ *
* @return The binary representation of the reason codes.
*/
@Override
@@ -153,7 +154,7 @@ public class CRLDistributionPoint extends DistributionPoint implements
/**
* Return a String representation of this distribution point.
- *
+ *
* @return The String representation of this distribution point.
* @see java.lang.Object#toString()
*/
@@ -163,7 +164,7 @@ public class CRLDistributionPoint extends DistributionPoint implements
}
/**
- * @see iaik.pki.revocation.CRLDistributionPoint#getIssuerName()
+ * Get CRL issuer-name.
*/
public String getIssuerName() {
return issuerName_;
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/ConfigurationPartsBuilder.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/ConfigurationPartsBuilder.java
index ff2f9a5..09ec921 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/ConfigurationPartsBuilder.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/config/ConfigurationPartsBuilder.java
@@ -581,7 +581,7 @@ public class ConfigurationPartsBuilder {
entry = new BlackListEntry(host, -1);
info("config.34", new Object[] { host });
} else {
- entry = new BlackListEntry(host, new Integer(port).intValue());
+ entry = new BlackListEntry(host, Integer.valueOf(port).intValue());
info("config.34", new Object[] { host + ":" + port });
}
@@ -631,7 +631,7 @@ public class ConfigurationPartsBuilder {
entry = new WhiteListEntry(host, -1);
info("config.49", new Object[] { host });
} else {
- entry = new WhiteListEntry(host, new Integer(port).intValue());
+ entry = new WhiteListEntry(host, Integer.valueOf(port).intValue());
info("config.49", new Object[] { host + ":" + port });
}
@@ -1522,7 +1522,7 @@ public class ConfigurationPartsBuilder {
* Returns the JDBC URL for the revocation archive database.
*
* @return the JDBC URL for the revocation archive database, or
- * nullnull, if the corresponding parameter is not set in the
* configuration.
*/
public String getRevocationArchiveJDBCURL() {
@@ -1534,7 +1534,7 @@ public class ConfigurationPartsBuilder {
* Returns the JDBC driver class name for the revocation archive database.
*
* @return the JDBC driver class name for the revocation archive database, or
- * nullnull, if the corresponding parameter is not set in the
* configuration.
*/
public String getRevocationArchiveJDBCDriverClass() {
@@ -1780,7 +1780,7 @@ public class ConfigurationPartsBuilder {
while ((modElem = (Element) modIter.nextNode()) != null) {
final String x509IssuerName = getElementValue(modElem, CONF + "X509IssuerName", null);
final String i = getElementValue(modElem, CONF + "Interval", null);
- final Integer interval = new Integer(i);
+ final Integer interval = Integer.valueOf(i);
map.put(ConfigurationProvider.normalizeX500Names(x509IssuerName), interval);
}
@@ -1880,7 +1880,7 @@ public class ConfigurationPartsBuilder {
final String x509IssuerName = ConfigurationProvider.normalizeX500Names(
getElementValue(modElem, CONF + "X509IssuerName", null));
final String i = getElementValue(modElem, CONF + "ValidityPeriod", null);
- final Integer interval = new Integer(i);
+ final Integer interval = Integer.valueOf(i);
map.put(x509IssuerName, interval);
Logger.debug("Set shortTimePeriodInterval: " + interval + " for Issuer: " + x509IssuerName);
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/cmssign/CMSSignatureCreationProfileImpl.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/cmssign/CMSSignatureCreationProfileImpl.java
index b43ec2f..e5b6025 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/cmssign/CMSSignatureCreationProfileImpl.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/cmssign/CMSSignatureCreationProfileImpl.java
@@ -81,13 +81,20 @@ public class CMSSignatureCreationProfileImpl
}
/**
- * Create a new XMLSignatureCreationProfileImpl.
+ * Creates a CMS based signature-creation profile.
*
- * @param createProfileCount Provides external information about the number of
- * calls to the signature creation module, using the
- * same request.
- * @param reservedIDs The set of IDs that must not be used while
- * generating new IDs.
+ * @param keySet Set of signing keys
+ * @param digestMethod Hash algorithm
+ * @param signedProperties List of signing properties
+ * @param securityLayerConform If true create a CAdES-B signature,
+ * otherwise CMS signature
+ * @param includeData If true create an embedded
+ * signature, otherwise a detached
+ * @param mimeType MimeType to be set
+ * @param isPAdESConform If true signature fulfill PAdES
+ * requirements
+ * @param rsaSsaPss If true use RSASSA-PSS algorithms,
+ * otherwise RSA#1.5
*/
public CMSSignatureCreationProfileImpl(
Set keySet,
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/CRLRetriever.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/CRLRetriever.java
index d1b776b..befeab7 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/CRLRetriever.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/CRLRetriever.java
@@ -43,7 +43,6 @@ import iaik.pki.store.revocation.RevocationStoreException;
* A customized implementation of
* {@link iaik.pki.store.revocation.RevocationInfoRetriever}. Will be used
* instead of the default implementation
- * {@link iaik.pki.store.revocation.CRLRetriever} to overcome a classloader
* problem in connection with the {@link java.net.URL} class in a Tomcat
* deployment environment.
*
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/DataBaseArchiveParameterImpl.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/DataBaseArchiveParameterImpl.java
index 22cceeb..0e12f89 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/DataBaseArchiveParameterImpl.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/config/DataBaseArchiveParameterImpl.java
@@ -28,7 +28,6 @@ import iaik.pki.store.revocation.archive.DataBaseArchiveParameters;
/**
* An implementation of the DataBaseArchiveParameter interface.
*
- * @see iaik.pki.store.revocation.archive.db.DataBaseArchiveParameter
* @author Patrick Peck
* @version $Id$
*/
@@ -46,9 +45,6 @@ public class DataBaseArchiveParameterImpl implements DataBaseArchiveParameters {
this.jDBCUrl = jDBCUrl;
}
- /**
- * @see iaik.pki.store.revocation.archive.db.DataBaseArchiveParameter#getJDBCUrl()
- */
@Override
public String getJDBCUrl() {
return jDBCUrl;
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/pki/store/truststore/TrustStoreProfileImpl.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/pki/store/truststore/TrustStoreProfileImpl.java
index 9ef3764..7a036ec 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/pki/store/truststore/TrustStoreProfileImpl.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/iaik/pki/store/truststore/TrustStoreProfileImpl.java
@@ -60,10 +60,9 @@ public class TrustStoreProfileImpl implements TrustStoreProfile {
/**
* Create a new TrustStoreProfileImpl.
*
- * @param config The MOA configuration data, from which trust store
- * configuration data is read.
- * @param trustProfileId The trust profile id on which this
- * TrustStoreProfile is based.
+ * @param trustProfileId The trust profile id on which this
+ * TrustStoreProfile is based.
+ * @param trustProfileUri File path to trust profile
* @throws MOAApplicationException The trustProfileId could not be
* found in the MOA configuration.
*/
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CMSSignatureVerificationInvoker.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CMSSignatureVerificationInvoker.java
index 19b3a12..7aca40e 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CMSSignatureVerificationInvoker.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CMSSignatureVerificationInvoker.java
@@ -248,7 +248,7 @@ public class CMSSignatureVerificationInvoker {
handlePDFResult(resultObject, responseBuilder, trustProfile);
}
} catch (final IndexOutOfBoundsException e) {
- throw new MOAApplicationException("2249", new Object[] { new Integer(sigIndex) });
+ throw new MOAApplicationException("2249", new Object[] { Integer.valueOf(sigIndex) });
}
}
}
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CreateCMSSignatureResponseBuilder.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CreateCMSSignatureResponseBuilder.java
index bc5d884..bca9b8e 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CreateCMSSignatureResponseBuilder.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/CreateCMSSignatureResponseBuilder.java
@@ -69,12 +69,12 @@ public class CreateCMSSignatureResponseBuilder {
/**
* Add a SignatureEnvironment element to the response.
*
- * @param signatureEnvironment The content to put under the
- * SignatureEnvironment element. This
- * should either be a dsig:Signature
- * element (in case of a detached signature) or the
- * signature environment containing the signature
- * (in case of an enveloping signature).
+ * @param base64value The content to put under the
+ * SignatureEnvironment element. This should
+ * either be a dsig:Signature element (in case
+ * of a detached signature) or the signature environment
+ * containing the signature (in case of an enveloping
+ * signature).
*/
public void addCMSSignature(String base64value) {
final CMSSignatureResponse responseElement =
@@ -84,7 +84,7 @@ public class CreateCMSSignatureResponseBuilder {
/**
* Add a ErrorResponse element to the response.
- *
+ *
* @param errorCode The error code.
* @param info Additional information about the error.
*/
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyCMSSignatureResponseBuilder.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyCMSSignatureResponseBuilder.java
index 813d28e..79b4c29 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyCMSSignatureResponseBuilder.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyCMSSignatureResponseBuilder.java
@@ -74,15 +74,26 @@ public class VerifyCMSSignatureResponseBuilder {
/**
* Add a verification result to the response.
*
- * @param result The result to add.
- * @param trustprofile The actual trustprofile
- * @param checkQCFromTSL true, if the TSL check verifies the
- * certificate as qualified, otherwise false.
- * @param checkSSCD true, if the TSL check verifies the
- * signature based on a SSDC, otherwise
- * false.
- * @param sscdSourceTSL true, if the SSCD information comes from
- * the TSL, otherwise false.
+ * @param result The result to add.
+ * @param trustProfile The actual trustprofile
+ * @param checkQC true, if the TSL check
+ * verifies the certificate as qualified,
+ * otherwise false.
+ * @param qcSourceTSL if QC info comes from the TSL,
+ * otherwise false.
+ * @param checkSSCD true, if the TSL check
+ * verifies the signature based on a SSDC,
+ * otherwise false.
+ * @param sscdSourceTSL true, if the SSCD
+ * information comes from the TSL,
+ * otherwise false.
+ * @param issuerCountryCode TSL issuer country
+ * @param adesResults Form validation results
+ * @param extendedCertificateCheckResult Extended validation results
+ * @param tslInfos Full TSL validation result
+ * @param extendedVerification true if extended
+ * validation was used, otherwise
+ * false
* @throws MOAException
*/
public void addResult(CMSSignatureVerificationResult result, TrustProfile trustProfile, boolean checkQC,
@@ -150,7 +161,7 @@ public class VerifyCMSSignatureResponseBuilder {
}
/**
- *
+ *
* @param result
* @param trustProfile
* @param checkQC
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyXMLSignatureResponseBuilder.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyXMLSignatureResponseBuilder.java
index 7e882ed..25ce8d1 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyXMLSignatureResponseBuilder.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/VerifyXMLSignatureResponseBuilder.java
@@ -515,7 +515,7 @@ public class VerifyXMLSignatureResponseBuilder {
try {
if (refInfo.isHashCalculated() && !refInfo.isHashValid()) {
- failedReferencesList.add(new Integer(i + 1));
+ failedReferencesList.add(Integer.valueOf(i + 1));
}
} catch (final HashUnavailableException e) {
// nothing to do here because we called refInfo.isHashCalculated first
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/XMLSignatureVerificationInvoker.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/XMLSignatureVerificationInvoker.java
index 2973b36..0fb2d82 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/XMLSignatureVerificationInvoker.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/server/invoke/XMLSignatureVerificationInvoker.java
@@ -539,7 +539,7 @@ public class XMLSignatureVerificationInvoker {
}
if (!found) {
- final Integer refIndex = new Integer(refData.getReferenceIndex());
+ final Integer refIndex = Integer.valueOf(refData.getReferenceIndex());
final String logMsg = msg.getMessage("invoker.01", new Object[] { refIndex });
failedReferencesList.add(refIndex);
@@ -581,8 +581,8 @@ public class XMLSignatureVerificationInvoker {
final int[] failedReferences = new int[] { ref.getReferenceIndex() };
final ReferencesCheckResultInfo checkInfo = factory.createReferencesCheckResultInfo(null,
failedReferences);
- final String logMsg = msg.getMessage("invoker.02", new Object[] { new Integer(ref
- .getReferenceIndex()) });
+ final String logMsg = msg.getMessage("invoker.02", new Object[] {
+ Integer.valueOf(ref.getReferenceIndex()) });
Logger.debug(new LogMsg(logMsg));
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/AdESResultUtils.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/AdESResultUtils.java
index 8e37b1c..8dd2a8b 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/AdESResultUtils.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/AdESResultUtils.java
@@ -21,8 +21,8 @@ import iaik.server.modules.resultcodes.ResultCodeValid;
public class AdESResultUtils {
- private static final int MAJORRESULTCODESKIPPED = new Integer(3);
- private static final int MAJORRESULTCODEERROR = new Integer(4);
+ private static final int MAJORRESULTCODESKIPPED = Integer.valueOf(3);
+ private static final int MAJORRESULTCODEERROR = Integer.valueOf(4);
public static Integer getResultCode(Integer adesCode) {
return adesCode;
@@ -114,9 +114,9 @@ public class AdESResultUtils {
minorInfo = "UNKNOWN_SUBFILTER";
} else if (resultCode.getCode().equals(ResultCode.CODE_NO_SIGNER_CERTIFICATE_FOUND)) {
minorInfo = "NO_SIGNER_CERTIFICATE_FOUND";
-
-
-
+
+
+
// pdf-as 3.x detection is removed from MOA-SP since 3.1.2
} else if (resultCode.getCode().equals(ResultCode.PDF_AS_SIGNATURE)) {
// minorInfo = "PDF_AS_SIGNATURE";
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/ExternalURIVerifier.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/ExternalURIVerifier.java
index be40a9e..221c361 100644
--- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/ExternalURIVerifier.java
+++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/util/ExternalURIVerifier.java
@@ -47,7 +47,7 @@ public class ExternalURIVerifier {
}
} else {
// check host and port
- final int iport = new Integer(bport).intValue();
+ final int iport = Integer.valueOf(bport).intValue();
if (ip.startsWith(bhost) && iport == port) {
Logger.debug(new LogMsg("Blacklist check: " + host + ":" + port + " (" + ip + ":" + port
+ " blacklisted"));
@@ -75,7 +75,7 @@ public class ExternalURIVerifier {
}
} else {
// check host and port
- final int iport = new Integer(bport).intValue();
+ final int iport = Integer.valueOf(bport).intValue();
if (ip.startsWith(bhost) && iport == port) {
Logger.debug(new LogMsg("Whitelist check: " + host + ":" + port + " (" + ip + ":" + port
+ " whitelisted"));
diff --git a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java
index 6127305..49047d7 100644
--- a/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java
+++ b/moaSig/moa-sig/src/main/java/at/gv/egovernment/moa/spss/server/service/ConfigurationServlet.java
@@ -62,8 +62,6 @@ public class ConfigurationServlet extends HttpServlet {
* Handle a HTTP GET request, used to indicated that the MOA configuration needs
* to be updated (reloaded).
*
- * @see javax.servlet.http.HttpServlet#doGet(HttpServletRequest,
- * HttpServletResponse)
*/
@Override
@SuppressWarnings({ "rawtypes", "unchecked" })
@@ -125,8 +123,6 @@ public class ConfigurationServlet extends HttpServlet {
/**
* Do the same as doGet.
*
- * @see javax.servlet.http.HttpServlet#doPost(HttpServletRequest,
- * HttpServletResponse)
*/
@Override
public void doPost(HttpServletRequest request, HttpServletResponse response)
@@ -140,8 +136,6 @@ public class ConfigurationServlet extends HttpServlet {
*
* Does an initial load of the MOA configuration to test if a working web
* service can be provided.
- *
- * @see javax.servlet.GenericServlet#init()
*/
@Override
public void init() throws ServletException {
--
cgit v1.2.3