애플리케이션이 SOVD 토큰을 검증하고 권한 부여 및 토큰 URL을 제공할 수 있도록 지원합니다.
AI 생성미검증모델: gemini-3.8-flash-medium · 노력: medium · 온도: 제어 불가 · 프롬프트: 49d1f84283f8출처열린 질문 (2)
독일어 가이드에서 번역됨gemini-3.8-flash-low · 2026-10-13 · 독일어 원문
애플리케이션이 SOVD 토큰을 검증하고 권한 부여 및 토큰 URL을 제공할 수 있도록 지원합니다.
클래스 ara::diag::SovdAuthorization은(는) 애플리케이션이 Diagnostic Server([SWS_DM_01490])에 대해 SOVD 권한 부여 인터페이스를 구현하는 데 사용됩니다. 권한 부여 및 토큰 엔드포인트의 리디렉션 URL을 확인하고 액세스 토큰을 검사하는 메서드를 제공합니다 ([SWS_DM_01483]). 메시지 수신은 인스턴스화 후 Offer()을(를) 통해 명시적으로 활성화해야 하며, 전달된 인증 객체는 검증 결과가 제공된 후 더 이상 사용할 수 없습니다.
컨텍스트
클래스 ara::diag::SovdAuthorization은(는) Service-Oriented Vehicle Diagnostics(SOVD)를 위한 권한 부여 및 인증 메커니즘을 제공하기 위해 Adaptive 애플리케이션 인터페이스를 제공합니다 ([SWS_DM_01490]). 진단 아키텍처 내에서 이는 Diagnostic Management(DM)의 Diagnostic Server와 차량 애플리케이션의 개별 권한 부여 로직 사이를 중재합니다 (SWS Diagnostics §7.3.3.2 “SOVD Request Validation and Verification”). 외부 SOVD 클라이언트가 클라이언트 확인 또는 토큰 검색을 위해 엔드포인트를 쿼리하면, Diagnostic Server는 대상 URL을 확인하기 위해 이러한 요청을 애플리케이션으로 전달합니다 ([SWS_DM_01471], [SWS_DM_01472]). HTTP 권한 부여 헤더가 포함된 수신 진단 요청의 경우, 클래스는 토큰의 유효성을 검사하고 전송된 액세스 역할을 정의합니다 ([SWS_DM_01470]). AUTOSAR는 여기서 로컬 애플리케이션 핸드오버 지점을 표준화하므로, 권한 부여 서버(예: OAuth 2.0)에 대한 실제 유효성 검사는 외부 네트워크 프로토콜을 통한 애플리케이션별 해석으로 수행될 것으로 보입니다. 질문 Q-6ce702103e4966c7 (열림)
ara::diag::SovdAuthorization의 인스턴스화는 ara::core::InstanceSpecifier 및 동시성 모드 ConcurrencyType을(를) 지정하여 생성자를 통해 명시적으로 수행됩니다 ([SWS_DM_01489]). InstanceSpecifier은(는) 매니페스트에서 DiagnosticSovdAuthorizationInterface의 유효한 PortPrototype을(를) 가리켜야 합니다. ConcurrencyType(kConcurrent 또는 kNotConcurrent)을(를) 통해 애플리케이션의 구현된 콜백 메서드가 스레드 안전하게 설계되어야 하는지 여부가 결정됩니다 ([SWS_DM_01483], [SWS_DM_01484], [SWS_DM_01485]).
생성 후 Diagnostic Server는 애플리케이션이 Offer() 메서드를 성공적으로 호출한 후에만 요청 전달을 시작합니다 ([SWS_DM_01487]). 해석: Offer() 이전에 도착하는 요청은 서버에 의해 폐기되거나 오류와 함께 거부될 가능성이 높습니다. 질문 Q-84330742a61f91a7 (열림) 요청 전달을 종료하기 위해 애플리케이션은 StopOffer()을(를) 호출합니다 ([SWS_DM_01486]). 마지막으로 가상 소멸자를 통해 객체가 해제됩니다 ([SWS_DM_01488]). 관리 호출 SovdAuthorization, Offer, StopOffer 및 소멸자는 스레드 안전하지 않습니다.
사용 경로
작동 중에 두 가지 주요 상호작용 경로가 발생합니다. 즉, 리디렉션 URL 제공과 활성 세션 토큰 검증입니다. SOVD 클라이언트가 클라이언트 확인 또는 토큰 요청을 위한 쿼리를 보내면 DM은 GetAuthorizationUrl()([SWS_DM_01485]) 또는 GetTokenUrl()([SWS_DM_01484])을(를) 호출합니다. 애플리케이션은 전달된 queryParameters 및 metaInfo을(를) 평가하고 대상 URL을 ara::core::Future<ara::core::String>(으)로 비동기 반환하며, 이에 따라 DM은 HTTP 307(Temporary Redirect)로 응답합니다 ([SWS_DM_01471], [SWS_DM_01472]).
후속 SOVD 요청에 신규 또는 변경된 HTTP Authorization 헤더가 포함된 경우 Diagnostic Server는 ValidateAuthorization()을(를) 호출합니다 ([SWS_DM_01470], [SWS_DM_01483]). 애플리케이션은 전달된 token을(를) 검증하고, 참조된 객체 ara::diag::ClientAuthentication에 해당 권한 역할을 할당하며([SWS_DM_01469]), Future을(를) 통해 ValidateAuthorizationOutput을(를) 반환합니다. 중요한 사전 조건: Future이(가) 준비되는 즉시 애플리케이션은 참조된 ClientAuthentication 객체를 더 이상 사용할 수 없습니다 ([SWS_DM_01483]). DM은 반환값(유효 기간 validUntil 및 identity)을 사용하여 재검사 없이 동일한 클라이언트의 후속 요청을 매핑하며([SWS_DM_01781], [SWS_DM_01782]), 이는 특히 SOVD 리소스 잠금에 필요합니다 ([SWS_DM_01783]).
오류는 ara::core::Result을(를) 통해 매핑되거나 반환된 ara::core::Future 내에 매핑됩니다:
초기화 및 모델링 오류: 인스턴스화가 실패하면 InstanceSpecifierMappingIntegrityViolation(유효하지 않은 모델 요소), PortInterfaceMappingViolation(잘못된 인터페이스 유형), ProcessMappingViolation(프로세스 참조 누락) 또는 InstanceSpecifierAlreadyInUseViolation([SWS_DM_01489])과 같은 위반이 보고됩니다.
Offer 시 릴리스 오류:Offer()은(는) 서비스가 이미 활성화된 경우 오류 발생 시 DiagOfferErrc::kAlreadyOffered을(를) 반환하고, 구성이 DEXT 데이터와 일치하지 않는 경우 DiagOfferErrc::kConfigurationMismatch을(를) 반환합니다 ([SWS_DM_01487]).
토큰 검증 오류: 토큰을 검증할 수 없는 경우 ValidateAuthorization()은(는) Future를 통해 DiagSovdErrc::kInvalidAccessToken(유효하지 않은 토큰) 또는 DiagSovdErrc::kTemporarilyNotAvailable(예: 온라인 검증을 위한 인증 서버에 연결할 수 없는 경우)을(를) 반환합니다 ([SWS_DM_01483]).
Get the URL that the SOVD client shall use for authorization. The SOVD client will be redirected to that URL. If OAuth 2.0 is used, this would be the URL to look up the Authorization Server’s authorize endpoint.
Get the URL that the SOVD client shall use to request a token. The SOVD client will be redirected to that URL. If OAuth 2.0 is used, this would be the URL to look up the Authorization Server’s token endpoint.
This function validates the authorization token sent by the SOVD client. The application shall validate the authorization token according to the authorization protocol used in the system and then according to the outcome set the respective roles as authorized in the clientAuthentication that is passed as parameter. If OAuth 2.0 is used, this would implement the validation that is supposed to happen in the Resource Server.
Get the URL that the SOVD client shall use for authorization. The SOVD client will be redirected to that URL. If OAuth 2.0 is used, this would be the URL to look up the Authorization Server’s authorize endpoint.
Get the URL that the SOVD client shall use to request a token. The SOVD client will be redirected to that URL. If OAuth 2.0 is used, this would be the URL to look up the Authorization Server’s token endpoint.
This Offer will enable the DM to forward request messages to this handler.
AI 생성미검증모델: gemini-3.8-flash-medium · 노력: medium · 온도: 제어 불가 · 프롬프트: 0834519262c7출처
독일어 가이드에서 번역됨gemini-3.8-flash-low · 2026-10-13 · 독일어 원문
클래스 ara::diag::SovdAuthorization의 동기 멤버 함수 Offer은(는) Diagnostic Management(DM)에 의한 요청 메시지의 연관된 핸들러 인스턴스로의 전달을 활성화합니다[SWS_DM_01487]. 파라미터를 받지 않으며, 성공적인 호출을 확인하거나 발생한 오류를 알리는 ara::core::Result<void>을(를) 반환합니다[SWS_DM_01487].
오류 처리와 관련하여 [SWS_DM_01487]은(는) 롤백 시맨틱과 함께 DiagOfferErrc의 두 가지 구체적인 오류 코드를 명시합니다:
DiagOfferErrc::kAlreadyOffered: 해당 인스턴스에 대해 서비스가 이미 제공되고 있는 경우 발생합니다[SWS_DM_01487].
InstanceSpeci- InstanceSpecifier either cannot be resolved in the model in the fierMappingIn- context of your executable, or it refers to a model element other tegrityViolation than a PortPrototype. PortInterfaceMap- A PortPrototype that is referenced by a pingViolation DiagnosticSovdAuthorizationPortMapping needs to be typed by a DiagnosticSovdAuthorizationInterface. ProcessMappingVio- Matching InstanceRef exists, but no matching (modelled) Process lation found that matches the (runtime) process. InstanceSpecifier- Violation message that is sent in case a constructor in the ara AlreadyInUseViola- framework was called with an InstanceSpecifier already in use in tion this process.
Parameter (in)
Parameter
Beschreibung
instanceSpecifier
InstanceSpecifier to a PortPrototype of a DiagnosticSovdAuthorizationInterface service instance in the manifest.
concurrencyType
Specifies if the interface is implemented as thread safe ( kConcurrent) or non-thread safe (kNotConcurrent).
Request a governed re-review of this record. The record is not changed immediately.
This StopOffer will disable the forwarding of request messages from DM.
AI 생성미검증모델: gemini-3.8-flash-medium · 노력: medium · 온도: 제어 불가 · 프롬프트: c318a30e32ad출처열린 질문 (1)
독일어 가이드에서 번역됨gemini-3.8-flash-low · 2026-10-13 · 독일어 원문
사용
클래스 ara::diag::SovdAuthorization(헤더 ara/diag/sovd_authorization.h)의 메서드 StopOffer은(는) Diagnostic Management(DM)에서 권한 부여 서비스로 수신 진단 요청이 전달되는 것을 차단하는 역할을 합니다[SWS_DM_01486]. 해당 함수는 void StopOffer() noexcept 시그니처를 갖습니다. 파라미터를 받지 않으며 호출자에게 반환값을 반환하지 않습니다[SWS_DM_01486].
오류 처리 및 동시성
해당 함수는 예외 안전(exception safe)(으)로 명시되어 있으며 예외를 발생시키지 않습니다[SWS_DM_01486]. 이 호출에 대해서는 특정 오류 코드 및 DET 또는 DEM으로의 오류 보고가 정의되어 있지 않습니다. 동시성과 관련하여 이 메서드는 스레드 안전하지 않음(not thread-safe)(으)로 분류됩니다[SWS_DM_01486]. 여러 스레드가 동일한 인스턴스 컨텍스트를 사용하는 경우, 호출 애플리케이션에 의해 접근이 동기화되어야 합니다. 해석: 호출은 주로 애플리케이션의 정상적인 종료 시 또는 권한 부여 준비 상태가 일시적으로 취소된 경우에 발생할 것으로 보입니다. 질문 Q-6c81f2dc7ee903ca (열림)
This function validates the authorization token sent by the SOVD client. The application shall validate the authorization token according to the authorization protocol used in the system and then according to the outcome set the respective roles as authorized in the clientAuthentication that is passed as parameter. If OAuth 2.0 is used, this would implement the validation that is supposed to happen in the Resource Server.
AI 생성미검증모델: gemini-3.8-flash-medium · 노력: medium · 온도: 제어 불가 · 프롬프트: 78d8310937f8출처
독일어 가이드에서 번역됨gemini-3.8-flash-low · 2026-10-13 · 독일어 원문
순수 가상 메서드 ValidateAuthorization은(는) SOVD 클라이언트의 요청에 Authorization HTTP 헤더가 포함되어 있고 해당 토큰이 아직 유효하게 검증되지 않은 경우 진단 서버에 의해 호출됩니다 [SWS_DM_01470]. 애플리케이션은 시스템에 구성된 프로토콜(예: Resource Server 컨텍스트의 OAuth 2.0)에 따라 전달된 권한 부여 토큰을 확인하고 클라이언트에 해당 역할을 할당합니다 [SWS_DM_01483].
metaInfo (const MetaInfo&): 진단 서비스 포트의 메타 정보입니다 [SWS_DM_01483].
clientAuthentication (ClientAuthentication&): 애플리케이션이 SOVD 클라이언트의 인증된 역할을 설정하는 데 사용하는 객체입니다 [SWS_DM_01483]. 반환된 Future이(가) 제공된 후 애플리케이션은 이 참조를 더 이상 사용할 수 없습니다 [SWS_DM_01483].
Diagnostic Server는 동일한 토큰을 가진 요청에 대해 할당된 역할을 validUntil에 도달할 때까지 인증된 것으로 간주하며 [SWS_DM_01469], 토큰 또는 ID를 기반으로 SOVD 클라이언트를 재인식합니다 [SWS_DM_01781][SWS_DM_01782]. 인증되지 않은 클라이언트는 HTTP 401로 잠금 접근이 거부되므로, 이러한 재인식은 임시 작업 및 SOVD 잠금 등에 필요합니다 [SWS_DM_01783].
오류가 발생하는 경우 Future은(는) DiagSovdErrc::kInvalidAccessToken(유효하지 않은 토큰) 또는 DiagSovdErrc::kTemporarilyNotAvailable(예: 인증 서버에 일시적으로 연결할 수 없음)로 확인(resolve)됩니다 [SWS_DM_01483]. 이 함수는 noexcept 및 예외 안전으로 지정되어 있습니다. 구현이 스레드 안전해야 하는지 여부는 생성자에서 전달된 ConcurrencyType을(를) 통해 제어됩니다 [SWS_DM_01483].
이 사용 지침은 AI에 의해 생성되었으며, AUTOSAR 사양만이 유일하게 구속력을 갖습니다.
conditional whether the function has to be implemented thread safe or non-thread safe is determined by the ConcurrencyType given in the constructor
Parameter (in)
Parameter
Beschreibung
token
The authorization token sent by the SOVD client in the HTTP Authorization header.
metaInfo
The meta information of a diagnostic service port.
clientAuthentication
Object used by the application to report the authenticated state of the SOVD client. After the returned Future is ready, the referenced object shall not be used any more by the application.
rollback_semantics The request currently can’t be served, e.g. in case the access token currently can’t be verified (e.g. because online verification is needed and the authentication server can’t be reached).
Request a governed re-review of this record. The record is not changed immediately.
gemini-3.8-flash-low· 2026-10-13 · 독일어 원문