X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=getdown%2Fsrc%2Fgetdown%2Fcore%2Fsrc%2Fmain%2Fjava%2Fcom%2Fthreerings%2Fgetdown%2Fspi%2FProxyAuth.java;fp=getdown%2Fsrc%2Fgetdown%2Fcore%2Fsrc%2Fmain%2Fjava%2Fcom%2Fthreerings%2Fgetdown%2Fspi%2FProxyAuth.java;h=22446ec0a518cde210f9d6fb0f11af43f75dc210;hb=f517e5ea31f1749617ac191137891cf87111550b;hp=0000000000000000000000000000000000000000;hpb=eb7de3c7621b2311470ab91b4af218a9f95ed8a3;p=jalview.git diff --git a/getdown/src/getdown/core/src/main/java/com/threerings/getdown/spi/ProxyAuth.java b/getdown/src/getdown/core/src/main/java/com/threerings/getdown/spi/ProxyAuth.java new file mode 100644 index 0000000..22446ec --- /dev/null +++ b/getdown/src/getdown/core/src/main/java/com/threerings/getdown/spi/ProxyAuth.java @@ -0,0 +1,32 @@ +// +// Getdown - application installer, patcher and launcher +// Copyright (C) 2004-2018 Getdown authors +// https://github.com/threerings/getdown/blob/master/LICENSE + +package com.threerings.getdown.spi; + +/** + * A service provider interface that handles the storage of proxy credentials. + */ +public interface ProxyAuth +{ + /** Credentials for a proxy server. */ + public static class Credentials { + public final String username; + public final String password; + public Credentials (String username, String password) { + this.username = username; + this.password = password; + } + } + + /** + * Loads the credentials for the app installed in {@code appDir}. + */ + public Credentials loadCredentials (String appDir); + + /** + * Encrypts and saves the credentials for the app installed in {@code appDir}. + */ + public void saveCredentials (String appDir, String username, String password); +}