2
0

Initial implementation of questions support.

This commit is contained in:
Maarten Billemont
2018-05-14 12:24:15 -04:00
parent 38a357cb28
commit 8d7c351912
9 changed files with 191 additions and 24 deletions

View File

@@ -20,11 +20,13 @@ package com.lyndir.masterpassword.gui.model;
import static com.lyndir.lhunath.opal.system.util.ObjectUtils.ifNotNullElse;
import com.google.common.collect.ImmutableCollection;
import com.google.common.collect.ImmutableList;
import com.google.common.primitives.UnsignedInteger;
import com.lyndir.masterpassword.MPAlgorithm;
import com.lyndir.masterpassword.MPResultType;
import com.lyndir.masterpassword.model.MPSite;
import com.lyndir.masterpassword.model.MPUser;
import com.lyndir.masterpassword.model.*;
import java.util.Collection;
import javax.annotation.Nullable;
@@ -95,6 +97,11 @@ public class IncognitoSite extends MPSite {
this.algorithm = algorithm;
}
@Override
public Collection<MPQuestion> getQuestions() {
return ImmutableList.of();
}
@Override
public UnsignedInteger getSiteCounter() {
return siteCounter;

View File

@@ -260,9 +260,7 @@ public abstract class PasswordFrame<U extends MPUser<S>, S extends MPSite> exten
@Override
public String call()
throws Exception {
return user.getMasterKey()
.siteResult( site.getSiteName(), site.getSiteCounter(), MPKeyPurpose.Authentication, null, site.getResultType(),
null, site.getAlgorithm() );
return site.getResult( MPKeyPurpose.Authentication, null, null );
}
} );
Futures.addCallback( passwordFuture, new FutureCallback<String>() {