Skip to content
This repository was archived by the owner on Jan 20, 2025. It is now read-only.

Commit 018d9c0

Browse files
committed
feat: add sts properties
1 parent 56a48eb commit 018d9c0

File tree

2 files changed

+34
-1
lines changed

2 files changed

+34
-1
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
/*
2+
* *******************************************************************************
3+
* Copyright (c) 2021,2024 Contributors to the Eclipse Foundation
4+
*
5+
* See the NOTICE file(s) distributed with this work for additional
6+
* information regarding copyright ownership.
7+
*
8+
* This program and the accompanying materials are made available under the
9+
* terms of the Apache License, Version 2.0 which is available at
10+
* https://www.apache.org/licenses/LICENSE-2.0.
11+
*
12+
* Unless required by applicable law or agreed to in writing, software
13+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
15+
* License for the specific language governing permissions and limitations
16+
* under the License.
17+
*
18+
* SPDX-License-Identifier: Apache-2.0
19+
* ******************************************************************************
20+
*/
21+
22+
package org.eclipse.tractusx.managedidentitywallets.sts;
23+
24+
import java.time.Duration;
25+
26+
import org.springframework.boot.context.properties.ConfigurationProperties;
27+
28+
@ConfigurationProperties(prefix = "sts")
29+
public record SecureTokenConfigurationProperties(Duration tokenDuration) {
30+
}

src/main/resources/application.yaml

+4-1
Original file line numberDiff line numberDiff line change
@@ -89,4 +89,7 @@ miw:
8989
auth-server-url: ${AUTH_SERVER_URL:http://localhost:8081}
9090
auth-url: ${miw.security.auth-server-url}/realms/${miw.security.realm}/protocol/openid-connect/auth
9191
token-url: ${miw.security.auth-server-url}/realms/${miw.security.realm}/protocol/openid-connect/token
92-
refresh-token-url: ${miw.security.token-url}
92+
refresh-token-url: ${miw.security.token-url}
93+
94+
sts:
95+
token-duration: 60000

0 commit comments

Comments
 (0)