GetSignatureModificationVerdict
Assinaturas digitais
Descrição
Diz se as atualizações anexadas após uma assinatura são do tipo que o nível de certificação do documento permite
Sintaxe
Delphi
Function TPDFlib.GetSignatureModificationVerdict(Const InputFile, Password, FieldName: WideString): Integer;Parâmetros
| InputFile | The signed document. |
|---|---|
| Password | A senha para abri-lo, ou uma string vazia. |
| FieldName | The signature field to judge. |
Valores retornados
| 1 | Nada foi anexado após a assinatura. |
|---|---|
| 2 | Apenas o nível de permissões de certificação foi alterado, com os allows anexados. |
| 3 | Algo que o nível não permite foi anexado. |
| 4 | Não foi possível determinar a resposta. |
| 5 | A assinatura não termina em uma fronteira de revisão, então há bytes dentro do intervalo que ela alega cobrir. |
| 0 | O arquivo ou o campo não pôde ser lido. |
Observações
A ISO 32000-1 §12.8.2.2 dá a uma assinatura de certificação um nível de permissão: 1 não permite mudança posterior nenhuma, 2 permite também preencher campos de formulário e assinar, 3 permite também anotações. Material de validação e carimbos de tempo de documento são permitidos em todos os níveis, então promover uma assinatura a validação de longo prazo nunca é lido como adulteração.
A result of 4 is not approval. It is returned when a certification's own structure could not be verified, when a field lock is present and which fields the later updates touched cannot be traced, when a later revision holds something that could not be read, and when the file carries bytes past the signed range that form no recognisable revision. In each of those cases something material is unknown, and treating it as permitted would be the wrong way to be wrong.
GetSignatureModificationDetail informa a revisão e o tipo de mudança por trás da resposta, e GetSignatureEffectiveMDPLevel reporta o nível aplicado.
Exemplo
case PDF.GetSignatureModificationVerdict('signed.pdf', '', 'Signature1') of
1, 2: ShowMessage('the signature still covers the document');
3: ShowMessage('not allowed: '+ PDF.GetSignatureModificationDetail);
else
ShowMessage('undetermined: '+ PDF.GetSignatureModificationDetail);
end;Veja também
GetSignatureEffectiveMDPLevel, GetSignatureModificationDetail, GetSignatureRevisionIndex, GetDocumentRevisionKind