001package com.nimbusds.jose; 002 003 004import java.util.Set; 005 006 007/** 008 * JSON Web Signature (JWS) header filter. Specifies accepted JWS algorithms 009 * and header parameters. 010 * 011 * @author Vladimir Dzhuvinov 012 * @version $version$ (2012-10-04) 013 */ 014public interface JWSHeaderFilter extends HeaderFilter { 015 016 017 /** 018 * Gets the names of the accepted JWS algorithms. These correspond to 019 * the {@code alg} JWS header parameter. 020 * 021 * @return The accepted JWS algorithms, as a read-only set, empty set 022 * if none. 023 */ 024 public Set<JWSAlgorithm> getAcceptedAlgorithms(); 025 026 027 /** 028 * Sets the names of the accepted JWS algorithms. These correspond to 029 * the {@code alg} JWS header parameter. 030 * 031 * @param acceptedAlgs The accepted JWS algorithms. Must be a subset of 032 * the supported algorithms and not {@code null}. 033 */ 034 public void setAcceptedAlgorithms(Set<JWSAlgorithm> acceptedAlgs); 035}