DEENESPTFRRUARHIKOZHNL

classe ara::diag::SovdAuthorization

[SWS_DM_01490] Upstream: RS_Diag_04268

class SovdAuthorization {...};

Class to implement the SOVD Authorization interfaces in the application.

Header-Datei#include "ara/diag/sovd_authorization.h"
Forwarding-Header#include "ara/diag/diag_fwd.h"
Scopenamespace ara::diag

Guia do utilizadorGERADO POR IA

Permite que aplicações validem tokens SOVD e forneçam URLs de autorização e de token.
GERADO POR IA não revisado Modelo: gemini-3.8-flash-medium · Esforço: medium · Temperatura: não controlável · Prompt: 49d1f84283f8 Procedência Perguntas em aberto (2)
traduzido do guia alemãogemini-3.8-flash-low · 2026-10-13 · Original em alemão

Permite que aplicações validem tokens SOVD e forneçam URLs de autorização e de token.

A classe ara::diag::SovdAuthorization serve a aplicações para a implementação das interfaces de autorização SOVD perante o Diagnostic Server ([SWS_DM_01490]). Ela disponibiliza métodos para determinação de URLs de redirecionamento para endpoints de autorização e de token, bem como para a verificação de tokens de acesso ([SWS_DM_01483]). A recepção de mensagens deve ser ativada explicitamente após a instanciação com Offer(), e o objeto de autenticação passado não deve mais ser utilizado após o fornecimento do resultado de validação.

Contexto

A classe ara::diag::SovdAuthorization fornece a interface de aplicação adaptativa para disponibilizar mecanismos de autorização e de autenticação para o Service-Oriented Vehicle Diagnostics (SOVD) ([SWS_DM_01490]). Dentro da arquitetura de diagnóstico, ela faz a mediação entre o Diagnostic Server do Diagnostic Management (DM) e a lógica de autorização individual da aplicação veicular (SWS Diagnostics §7.3.3.2 «SOVD Request Validation and Verification»). Quando um cliente SOVD externo consulta endpoints para verificação de cliente ou para recuperação de tokens, o Diagnostic Server encaminha essas requisições à aplicação para determinar as URLs de destino ([SWS_DM_01471], [SWS_DM_01472]). Em requisições de diagnóstico de entrada com cabeçalho de autorização HTTP, a classe verifica a validade do token e define papéis de acesso transferidos ([SWS_DM_01470]). A validação real perante um servidor de autorização (como OAuth 2.0) provavelmente ocorre como uma interpretação específica da aplicação por meio de protocolos de rede externos, uma vez que a AUTOSAR padroniza aqui o ponto local de entrega da aplicação. Pergunta Q-6ce702103e4966c7 (aberta)

SovdAuthContext client SOVD-Client dm Diagnostic Server (DM) client->dm SOVD-Request dm->client HTTP 307 / SOVD-Response handler SovdAuthorization (Anwendung) dm->handler Get*Url() / ValidateAuthorization() authserver Autorisierungs-Server (extern/OAuth 2.0) handler->authserver Token-Validierung (Interpretation)

Diagrama de contexto: interação entre cliente SOVD, Diagnostic Server (DM), SovdAuthorization e serviço de autorização externo. Fontes: [SWS_DM_01470], [SWS_DM_01471], [SWS_DM_01472], SWS Diagnostics §7.3.3.2.1 «SOVD – Authorization»

Ciclo de vida

A instanciação de ara::diag::SovdAuthorization ocorre explicitamente através do construtor sob indicação de um ara::core::InstanceSpecifier, bem como do modo de concorrência ConcurrencyType ([SWS_DM_01489]). O InstanceSpecifier deve apontar no manifesto para um PortPrototype válido de um DiagnosticSovdAuthorizationInterface. Através do ConcurrencyType (kConcurrent ou kNotConcurrent), define-se se os métodos de callback implementados da aplicação precisam ser projetados como seguros para threads ([SWS_DM_01483], [SWS_DM_01484], [SWS_DM_01485]).

Após a construção, o Diagnostic Server só encaminha requisições quando a aplicação tiver chamado o método Offer() com sucesso ([SWS_DM_01487]). Interpretação: requisições que chegam antes do Offer() são provavelmente descartadas pelo servidor ou rejeitadas com erro. Pergunta Q-84330742a61f91a7 (aberta) Para encerrar o encaminhamento de requisições, a aplicação chama StopOffer() ([SWS_DM_01486]). Por fim, o objeto é liberado através do destrutor virtual ([SWS_DM_01488]). As chamadas administrativas SovdAuthorization, Offer, StopOffer e o destrutor não são seguros para threads.

Caminho de utilização

Em operação corrente ocorrem dois caminhos essenciais de interação: a disponibilização de URLs de redirecionamento e a validação de tokens de sessão ativos. Se um cliente SOVD enviar uma consulta para verificação de cliente ou para requisição de um token, o DM chama GetAuthorizationUrl() ([SWS_DM_01485]) ou GetTokenUrl() ([SWS_DM_01484]). A aplicação avalia os queryParameters fornecidos, bem como a metaInfo, e retorna a URL de destino de forma assíncrona como ara::core::Future<ara::core::String>, após o que o DM responde com um HTTP 307 (Temporary Redirect) ([SWS_DM_01471], [SWS_DM_01472]).

Se uma requisição SOVD subsequente contiver um cabeçalho HTTP Authorization novo ou modificado, o Diagnostic Server chama ValidateAuthorization() ([SWS_DM_01470], [SWS_DM_01483]). A aplicação valida o token transmitido, atribui ao objeto referenciado ara::diag::ClientAuthentication os respectivos papéis de autorização ([SWS_DM_01469]) e retorna um ValidateAuthorizationOutput através do Future. Pré-requisito importante: assim que o Future estiver disponível, a aplicação não deve mais usar o objeto ClientAuthentication referenciado ([SWS_DM_01483]). O DM utiliza os valores de retorno (tempo de validade validUntil e identity) para associar requisições subsequentes do mesmo cliente sem nova verificação ([SWS_DM_01781], [SWS_DM_01782]), o que é necessário em particular para bloqueios de recursos SOVD ([SWS_DM_01783]).

Fluxo da validação de token SOVDSOVD-ClientDiagnostic Server (DM)SovdAuthorizationClientAuthenticationRequisição SOVD com cabeçalho de autorizaçãoValidateAuthorization(token, metaInfo, clientAuth)Validar token internamente ou onlineRollen als autorisiert setzenFuture ready: ValidateAuthorizationOutputReidentificar cliente & assumir funçõesHTTP 200 OK / acesso ao recurso concedido

Diagrama de sequência: fluxo da validação de token via ValidateAuthorization e atribuição de papéis. Fontes: [SWS_DM_01469], [SWS_DM_01470], [SWS_DM_01483], SWS Diagnostics §7.3.3.2.1 «SOVD – Authorization»

Cenários de erro

Os erros são mapeados via ara::core::Result ou dentro do ara::core::Future retornado:

  • Erros de inicialização e modelagem: se a instanciação falhar, violações são reportadas, tais como InstanceSpecifierMappingIntegrityViolation (elemento de modelo inválido), PortInterfaceMappingViolation (tipo de interface incorreto), ProcessMappingViolation (referência de processo ausente) ou InstanceSpecifierAlreadyInUseViolation ([SWS_DM_01489]).
  • Erros de liberação no Offer: em caso de falha, Offer() retorna DiagOfferErrc::kAlreadyOffered caso o serviço já esteja ativo, ou DiagOfferErrc::kConfigurationMismatch caso a configuração não coincida com os dados DEXT ([SWS_DM_01487]).
  • Erros na validação de token: caso um token não possa ser verificado, ValidateAuthorization() retorna via future DiagSovdErrc::kInvalidAccessToken (token inválido) ou DiagSovdErrc::kTemporarilyNotAvailable (por exemplo, quando o servidor de autenticação para verificação online não estiver acessível) ([SWS_DM_01483]).
  • Determinação de URL: para GetAuthorizationUrl() e GetTokenUrl(), não estão definidos códigos de erro padronizados ([SWS_DM_01484], [SWS_DM_01485]).

Este guia baseia-se exclusivamente nas especificações da Release R25-11 da AUTOSAR.

Mapa de membros

Diagrama de classes

Hohle Dreieckspfeile = Vererbung (zeigt zur Basisklasse); Klicken öffnet die jeweilige Klassenseite.

G nara__diag__SovdAuthorization23 SovdAuthorization + ~SovdAuthorization() + SovdAuthorization() + GetAuthorizationUrl() + GetTokenUrl() + Offer() + StopOffer() + ValidateAuthorization()

Vista de detalhes

Selecione uma entrada no índice.

Construtores e destrutor

Constructs the port for SOVD Authorization interface.

explicit SovdAuthorization (ara::core::InstanceSpecifier instance Specifier, ConcurrencyType concurrencyType) noexcept;

Destructor of SovdAuthorization.

virtual ~SovdAuthorization () noexcept;

Métodos

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.

virtual ara::core::Future< ara::core::String > GetAuthorizationUrl (const ara::core::Map< const ara::core::StringView, const ara::core::Vector< const ara::core::StringView > > &queryParameters, const MetaInfo &metaInfo) noexcept=0;
GetTokenUrl função

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.

virtual ara::core::Future< ara::core::String > GetTokenUrl (const ara::core::Map< const ara::core::StringView, const ara::core::Vector< const ara::core::StringView > > &queryParameters, const MetaInfo &meta Info) noexcept=0;
Offer função

This Offer will enable the DM to forward request messages to this handler.

ara::core::Result< void > Offer () noexcept;
StopOffer função

This StopOffer will disable the forwarding of request messages from DM.

void StopOffer () noexcept;

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.

virtual ara::core::Future< ValidateAuthorizationOutput > Validate Authorization (ara::core::StringView token, const MetaInfo &metaInfo, ClientAuthentication &clientAuthentication) noexcept=0;

Tipos aninhados

Documentação dos métodos

função GetAuthorizationUrl [SWS_DM_01485] Upstream: RS_Diag_04268

virtual ara::core::Future< ara::core::String > GetAuthorizationUrl (const ara::core::Map< const ara::core::StringView, const ara::core::Vector< const ara::core::StringView > > &queryParameters, const MetaInfo &metaInfo) noexcept=0;

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.

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitconditional whether the function has to be implemented thread safe or non-thread safe is determined by the ConcurrencyType given in the constructor

Parameter (in)

ParameterBeschreibung
queryParametersThe query parameters passed in the request.
metaInfoThe meta information of a diagnostic service port.

Rückgabewert

TypBeschreibung
ara::core::Future<ara::core::String >Returns the URL, that the SOVD client shall use for authorization.

Fehler

FehlercodeBeschreibung
This function does not specify any standardized errors.

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/SWS_DM_01485
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01485@rel:R25-11#1fe79a48
Content hash
1fe79a48
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01485
Status: valid/unmigrated Version: rel:R25-11#d45641ff Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01485@rel:R25-11#d45641ff
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#8d714d092026-09-30
  • R22-11rel:R22-11#16824a3e2026-10-14
  • R23-11rel:R23-11#76cd545a2026-10-14
  • R24-11rel:R24-11#6525fcf82026-10-14
  • R25-11rel:R25-11#d45641ff2026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill

função GetTokenUrl [SWS_DM_01484] Upstream: RS_Diag_04268

virtual ara::core::Future< ara::core::String > GetTokenUrl (const ara::core::Map< const ara::core::StringView, const ara::core::Vector< const ara::core::StringView > > &queryParameters, const MetaInfo &meta Info) noexcept=0;

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.

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitconditional whether the function has to be implemented thread safe or non-thread safe is determined by the ConcurrencyType given in the constructor

Parameter (in)

ParameterBeschreibung
queryParametersThe query parameters passed in the request.
metaInfoThe meta information of a diagnostic service port.

Rückgabewert

TypBeschreibung
ara::core::Future<ara::core::String >Returns the URL that the SOVD client shall use to request a token.

Fehler

FehlercodeBeschreibung
This function does not specify any standardized errors.

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/SWS_DM_01484
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01484@rel:R25-11#9cb576f8
Content hash
9cb576f8
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01484
Status: valid/unmigrated Version: rel:R25-11#f6a201d9 Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01484@rel:R25-11#f6a201d9
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#7e533d902026-09-30
  • R22-11rel:R22-11#17e901a02026-10-14
  • R23-11rel:R23-11#42f1bade2026-10-14
  • R24-11rel:R24-11#a069b6f52026-10-14
  • R25-11rel:R25-11#f6a201d92026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill

função Offer [SWS_DM_01487] Upstream: RS_Diag_04268

ara::core::Result< void > Offer () noexcept;

This Offer will enable the DM to forward request messages to this handler.

GERADO POR IA não revisado Modelo: gemini-3.8-flash-medium · Esforço: medium · Temperatura: não controlável · Prompt: 0834519262c7 Procedência
traduzido do guia alemãogemini-3.8-flash-low · 2026-10-13 · Original em alemão

A função membro síncrona Offer da classe ara::diag::SovdAuthorization ativa o encaminhamento de mensagens de pedido pelo Diagnostic Management (DM) para a instância de manipulador associada [SWS_DM_01487]. Não aceita parâmetros e devolve um ara::core::Result<void>, que confirma a chamada bem-sucedida ou reporta um erro ocorrido [SWS_DM_01487].

No que diz respeito ao tratamento de erros, [SWS_DM_01487] especifica dois códigos de erro concretos de DiagOfferErrc com semântica de rollback:

  • DiagOfferErrc::kAlreadyOffered: ocorre quando o serviço já está a ser oferecido para esta instância [SWS_DM_01487].
  • DiagOfferErrc::kConfigurationMismatch: reporta que a configuração não coincide com os dados de descrição DEXT [SWS_DM_01487].

Relativamente às propriedades de execução, a chamada está declarada como segura em termos de exceções (exception safe), mas é considerada não segura entre threads (not thread-safe) [SWS_DM_01487]. A função não pode, por isso, ser chamada concorrentemente para a mesma instância.

Na interação com o DM, a função corresponde ao padrão geral de disponibilização das interfaces de diagnóstico do AUTOSAR Adaptive, tal como é utilizado também para rotinas genéricas ou serviços DoIP (por exemplo [SWS_DM_00557], [SWS_DM_00725] ou [SWS_DM_00809]). Enquanto um manipulador não tiver sido registado através de Offer, o DM não encaminha pedidos para a aplicação ou serve-os com valores de substituição predefinidos [SWS_DM_01487], [SWS_DM_01525], [SWS_DM_01527].

Este texto foi criado por uma IA. Todas as informações baseiam-se exclusivamente no excerto de especificação disponibilizado.

Guia do implementador em breve (complexidade I1)

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitnot thread-safe

Rückgabewert

TypBeschreibung
ara::core::Result< void >Returns nothing or an error.

Fehler

FehlercodeBeschreibung
DiagOfferErrc::kAlreadyOfferedrollback_semantics The service is already offered.
DiagOfferErrc::kConfigurationMismatchrollback_semantics monitor configuration does not match DEXT

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/SWS_DM_01487
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01487@rel:R25-11#c1bfb469
Content hash
c1bfb469
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01487
Status: valid/unmigrated Version: rel:R25-11#a9605b85 Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01487@rel:R25-11#a9605b85
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#1ee581c62026-09-30
  • R22-11rel:R22-11#d1dad9c62026-10-14
  • R23-11rel:R23-11#853e9a012026-10-14
  • R24-11rel:R24-11#59ae33f32026-10-14
  • R25-11rel:R25-11#a9605b852026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill

função SovdAuthorization [SWS_DM_01489] Upstream: RS_Diag_04268, RS_AP_00170, RS_AP_00171, RS_AP_00172, RS_AP_00173

explicit SovdAuthorization (ara::core::InstanceSpecifier instance Specifier, ConcurrencyType concurrencyType) noexcept;

Constructs the port for SOVD Authorization interface.

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitnot thread-safe
Verletzungen (Violations)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)

ParameterBeschreibung
instanceSpecifierInstanceSpecifier to a PortPrototype of a DiagnosticSovdAuthorizationInterface service instance in the manifest.
concurrencyTypeSpecifies 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.

Record
AUTOSAR/AP/record/SWS_DM_01489
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01489@rel:R25-11#bf207ee2
Content hash
bf207ee2
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01489
Status: valid/unmigrated Version: rel:R25-11#c9585cf9 Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01489@rel:R25-11#c9585cf9
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#af23d0c72026-09-30
  • R22-11rel:R22-11#45eb7d512026-10-14
  • R23-11rel:R23-11#97066c872026-10-14
  • R24-11rel:R24-11#07afb8a72026-10-14
  • R25-11rel:R25-11#c9585cf92026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill

função StopOffer [SWS_DM_01486] Upstream: RS_Diag_04268

void StopOffer () noexcept;

This StopOffer will disable the forwarding of request messages from DM.

GERADO POR IA não revisado Modelo: gemini-3.8-flash-medium · Esforço: medium · Temperatura: não controlável · Prompt: c318a30e32ad Procedência Perguntas em aberto (1)
traduzido do guia alemãogemini-3.8-flash-low · 2026-10-13 · Original em alemão

usar

O método StopOffer da classe ara::diag::SovdAuthorization (cabeçalho ara/diag/sovd_authorization.h) serve para impedir o encaminhamento de pedidos de diagnóstico recebidos do Diagnostic Management (DM) para o serviço de autorização [SWS_DM_01486]. A função possui a assinatura void StopOffer() noexcept. Não aceita parâmetros e não devolve qualquer valor de retorno ao chamador [SWS_DM_01486].

Tratamento de erros e simultaneidade

A função está especificada como segura em termos de exceções (exception safe) e não lança exceções [SWS_DM_01486]. Não estão previstos códigos de erro específicos nem mensagens de erro para o DET ou DEM para esta chamada. No que diz respeito à concorrência, o método está classificado como não seguro entre threads (not thread-safe) [SWS_DM_01486]. Se várias threads utilizarem o mesmo contexto de instância, o acesso tem de ser sincronizado pela aplicação chamadora. Interpretação: uma chamada deverá ocorrer sobretudo aquando do encerramento ordenado da aplicação ou em caso de revogação temporária da prontidão de autorização. Pergunta Q-6c81f2dc7ee903ca (aberta)

Interação

O conceito segue o padrão de desenho geral para interfaces no diagnóstico AUTOSAR Adaptive: a designação StopOffer foi escolhida com base nas interfaces de serviço de ara::com, mas representa uma implementação autónoma dentro de ara::diag AUTOSAR_AP_SWS_Diagnostics §7.3.4.1.2 «Monitors». A mesma semântica de desativação encontra-se a nível de todo o módulo em muitas outras interfaces de porto, por exemplo em GenericRoutine [SWS_DM_00558], Authentication [SWS_DM_01131], CommunicationControl [SWS_DM_00810], bem como em Monitor [SWS_DM_01089].

Esta nota de utilização foi gerada automaticamente com base na especificação AUTOSAR AP R25-11.

Guia do implementador em breve (complexidade I2)

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitnot thread-safe

Rückgabewert

TypBeschreibung
None

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/SWS_DM_01486
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01486@rel:R25-11#227e80a8
Content hash
227e80a8
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01486
Status: valid/unmigrated Version: rel:R25-11#9bb7ae44 Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01486@rel:R25-11#9bb7ae44
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#30189eb12026-09-30
  • R22-11rel:R22-11#14fbd18b2026-10-14
  • R23-11rel:R23-11#31cc13ad2026-10-14
  • R24-11rel:R24-11#ac3ee7ea2026-10-14
  • R25-11rel:R25-11#9bb7ae442026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill

função ValidateAuthorization [SWS_DM_01483] Upstream: RS_Diag_04268

virtual ara::core::Future< ValidateAuthorizationOutput > Validate Authorization (ara::core::StringView token, const MetaInfo &metaInfo, ClientAuthentication &clientAuthentication) noexcept=0;

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.

GERADO POR IA não revisado Modelo: gemini-3.8-flash-medium · Esforço: medium · Temperatura: não controlável · Prompt: 78d8310937f8 Procedência
traduzido do guia alemãogemini-3.8-flash-low · 2026-10-13 · Original em alemão

O método puramente virtual ValidateAuthorization é chamado pelo servidor de diagnóstico quando uma solicitação de um cliente SOVD contém um cabeçalho HTTP Authorization e seu token ainda não foi validado [SWS_DM_01470]. A aplicação verifica o token de autorização passado de acordo com o protocolo configurado no sistema (por exemplo, OAuth 2.0 no contexto de um Resource Server) e atribui as respectivas funções ao cliente [SWS_DM_01483].

A especificação da interface abrange os seguintes parâmetros e retornos SWS Diagnostics §8.52.1.1.3.5 «ValidateAuthorization»:

  • token (ara::core::StringView): O token de acesso transmitido a partir do cabeçalho HTTP [SWS_DM_01483].
  • metaInfo (const MetaInfo&): Metainformações da porta de serviço de diagnóstico [SWS_DM_01483].
  • clientAuthentication (ClientAuthentication&): Objeto por meio do qual a aplicação define as funções autenticadas do cliente SOVD [SWS_DM_01483]. Após a disponibilização do Future retornado, a aplicação não deve mais utilizar esta referência [SWS_DM_01483].
  • Valor de retorno: Um ara::core::Future<ValidateAuthorizationOutput> [SWS_DM_01483]. Em caso de validação bem-sucedida, a estrutura ValidateAuthorizationOutput [SWS_DM_01927] contém o carimbo de data/hora de validade validUntil [SWS_DM_01820], bem como a identificação do cliente identity [SWS_DM_01819].

O Diagnostic Server considera as funções atribuídas para solicitações com token idêntico como autenticadas até atingir validUntil [SWS_DM_01469] e reconhece o cliente SOVD com base no token ou na identidade [SWS_DM_01781] [SWS_DM_01782]. Esse reconhecimento é necessário, entre outros, para operações temporárias e bloqueios SOVD, já que o acesso a bloqueios é negado a clientes não autenticados com HTTP 401 [SWS_DM_01783].

Em caso de erro, o Future é resolvido com DiagSovdErrc::kInvalidAccessToken (token inválido) ou DiagSovdErrc::kTemporarilyNotAvailable (por exemplo, servidor de autenticação temporariamente inacessível) [SWS_DM_01483]. A função está especificada como noexcept e segura contra exceções; se a implementação deve ser segura para threads é controlado por meio do ConcurrencyType passado no construtor [SWS_DM_01483].

Esta nota de uso foi gerada por uma IA; vinculativa é exclusivamente a especificação AUTOSAR.

Guia do implementador em breve (complexidade I1)

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitconditional whether the function has to be implemented thread safe or non-thread safe is determined by the ConcurrencyType given in the constructor

Parameter (in)

ParameterBeschreibung
tokenThe authorization token sent by the SOVD client in the HTTP Authorization header.
metaInfoThe meta information of a diagnostic service port.
clientAuthenticationObject 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.

Rückgabewert

TypBeschreibung
ara::core::Future<ValidateAuthorizationOutput >Either ValidateAuthorizationOutput (for a successful validation) or an error code.

Fehler

FehlercodeBeschreibung
DiagSovdErrc::kInvalidAccessTokenrollback_semantics The access token provided by the client is invalid.
DiagSovdErrc::kTemporarilyNotAvailablerollback_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.

Record
AUTOSAR/AP/record/SWS_DM_01483
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01483@rel:R25-11#a7eeb205
Content hash
a7eeb205
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01483
Status: valid/unmigrated Version: rel:R25-11#3ab745cf Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01483@rel:R25-11#3ab745cf
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#8a2fbb692026-09-30
  • R22-11rel:R22-11#600c614a2026-10-14
  • R23-11rel:R23-11#0433454d2026-10-14
  • R24-11rel:R24-11#7b10afcc2026-10-14
  • R25-11rel:R25-11#3ab745cf2026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill

função ~SovdAuthorization [SWS_DM_01488] Upstream: RS_Diag_04268

virtual ~SovdAuthorization () noexcept;

Destructor of SovdAuthorization.

Header-Datei#include "ara/diag/sovd_authorization.h"
Scopeclass ara::diag::SovdAuthorization
Exception-Sicherheitexception safe
Thread-Sicherheitnot thread-safe

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/SWS_DM_01488
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01488@rel:R25-11#ff2f0291
Content hash
ff2f0291
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01488
Status: valid/unmigrated Version: rel:R25-11#4b141c27 Versionshistorie & Revisions (1 transition, 5 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01488@rel:R25-11#4b141c27
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#3e0dc97d2026-09-30
  • R22-11rel:R22-11#a7d4ac032026-10-14
  • R23-11rel:R23-11#b65bc1cb2026-10-14
  • R24-11rel:R24-11#05fce8112026-10-14
  • R25-11rel:R25-11#4b141c272026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill