public boolean filterArtifactInfo(ArtifactInfo artifactInfo) {
try {
Repository repository = this.repositoryRegistry.getRepository(artifactInfo.repository);
if (MavenRepository.class.isAssignableFrom(repository.getClass())) {
MavenRepository mr = (MavenRepository) repository;
Gav gav =
new Gav(artifactInfo.groupId, artifactInfo.artifactId, artifactInfo.version,
artifactInfo.classifier, mr.getArtifactPackagingMapper().getExtensionForPackaging(
artifactInfo.packaging), null, null, null, false, null, false, null);
ResourceStoreRequest req = new ResourceStoreRequest(mr.getGavCalculator().gavToPath(gav));
return this.nexusItemAuthorizer.authorizePath(mr, req, Action.read);
}
else {
// we are only filtering maven artifacts