git-svn-id: svn://svn.jdownloader.org/jdownloader/trunk@12369 ebf7c1c2-ba36-0410-9fe8-c592906822b4
This commit is contained in:
Greeny 2010-08-23 21:24:46 +00:00
parent 75b89024ab
commit cd0d3e4cf3
97 changed files with 259 additions and 338 deletions

View File

@ -81,6 +81,5 @@
<classpathentry kind="lib" path="ressourcen/libs/jackson-mapper.jar"/>
<classpathentry kind="lib" path="ressourcen/libs/svnkit.jar" sourcepath="ressourcen/code-ressourcen/svnkitsrc.zip"/>
<classpathentry kind="lib" path="ressourcen/libs/laf/trident.jar"/>
<classpathentry kind="lib" path="ressourcen/libs/appworkutilities.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>

View File

@ -192,8 +192,6 @@ public class DownloadLink extends Property implements Serializable, Comparable<D
*/
private String customIconText = null;
private transient DownloadLinkInfo downloadLinkInfo;
/**
* Erzeugt einen neuen DownloadLink
*

View File

@ -9,6 +9,7 @@ import jd.utils.locale.JDL;
public class DownloadLinkInfo {
private DownloadLink link = null;
private String formattedSize = null;
private String formattedLoaded = null;
private String formattedRemaining = null;
@ -21,7 +22,7 @@ public class DownloadLinkInfo {
private long lastReset = 0;
private boolean formattedSizeReset = false;
private boolean dateAddedReset = false;
private boolean dateFinishedReset = false;;
private boolean dateFinishedReset = false;
private static SimpleDateFormat dateFormat = null;

View File

@ -105,8 +105,6 @@ public class FilePackage extends Property implements Serializable, DownloadLinkL
private long finishedDate = -1l;
private transient FilePackageInfo filePackageInfo = null;
public void addListener(FilePackageListener l) {
broadcaster.addListener(l);
}

View File

@ -19,10 +19,8 @@ public class FilePackageInfo {
private String statusString = null;
private String progressString = null;
private long lastReset = 0;
private boolean dateAddedReset = false;
private boolean dateFinishedReset = false;;
private boolean dateFinishedReset = false;
private static SimpleDateFormat dateFormat = null;
private static String strDownloadLinkActive = JDL.L("gui.treetable.packagestatus.links_active", "Active");

View File

@ -70,20 +70,36 @@ public abstract class Plugin implements ActionListener {
}
}
public static String getUserInput(String message, CryptedLink link) throws DecrypterException {
String password = JDUtilities.getUserInput(message, link);
if (password == null) throw new DecrypterException(DecrypterException.PASSWORD);
return password;
}
/**
*
* @param message
* The message to be displayed or <code>null</code> to display a
* Password prompt
* @param link
* the {@link DownloadLink}
* @return the entered password
* @throws PluginException
* if the user aborts the input
*/
public static String getUserInput(String message, DownloadLink link) throws PluginException {
String password = JDUtilities.getUserInput(message, link);
String password = PluginUtils.askPassword(message, link);
if (password == null) throw new PluginException(LinkStatus.ERROR_FATAL, JDL.L("plugins.errors.wrongpassword", "Password wrong"));
return password;
}
public static String getUserInput(String message, String defaultmessage, CryptedLink link) throws DecrypterException {
String password = JDUtilities.getUserInput(message, defaultmessage, link);
/**
*
* @param message
* The message to be displayed or <code>null</code> to display a
* Password prompt
* @param link
* the {@link CryptedLink}
* @return the entered password
* @throws DecrypterException
* if the user aborts the input
*/
public static String getUserInput(String message, CryptedLink link) throws DecrypterException {
String password = PluginUtils.askPassword(message, link);
if (password == null) throw new DecrypterException(DecrypterException.PASSWORD);
return password;
}
@ -396,11 +412,6 @@ public abstract class Plugin implements ActionListener {
* Initialisiert das Plugin vor dem ersten Gebrauch
*/
public void init() {
}
@Deprecated
public void setAcceptOnlyURIs(boolean acceptCompleteLinks) {
}
}

View File

@ -21,6 +21,7 @@ import java.nio.charset.CharacterCodingException;
import jd.gui.UserIO;
import jd.gui.swing.components.Balloon;
import jd.http.Browser;
import jd.utils.JDUtilities;
import jd.utils.locale.JDL;
import org.appwork.utils.logging.Log;
@ -34,11 +35,45 @@ import org.mozilla.javascript.Scriptable;
* @author Coalado
*/
public class PluginUtils {
private static final String JDL_PREFIX = "jd.plugins.PluginUtils.";
/**
* Asks the user to entere a password for plugin
*/
public static String askPassword(final Plugin plg) {
return UserIO.getInstance().requestInputDialog(0, JDL.LF("jd.plugins.PluginUtils.askPassword", "Please enter the password for %s", plg.getHost()), "");
return askPassword(plg.getHost(), "");
}
public static String askPassword(String message, final DownloadLink link) {
try {
link.getLinkStatus().addStatus(LinkStatus.WAITING_USERIO);
link.requestGuiUpdate();
if (message == null) message = JDL.LF(JDL_PREFIX + "askPassword", "Please enter the password for %s", link.getName());
final String password = askPassword(message, link.getDecrypterPassword());
link.requestGuiUpdate();
return password;
} finally {
link.getLinkStatus().removeStatus(LinkStatus.WAITING_USERIO);
}
}
public static String askPassword(String message, final CryptedLink link) {
link.getProgressController().setStatusText(JDL.L("gui.linkgrabber.waitinguserio", "Waiting for user input"));
if (message == null) message = JDL.LF(JDL_PREFIX + "askPassword", "Please enter the password for %s", link.getCryptedUrl());
final String password = askPassword(message, link.getDecrypterPassword());
link.getProgressController().setStatusText(null);
return password;
}
public static String askPassword(final String message, final String defaultmessage) {
synchronized (JDUtilities.USERIO_LOCK) {
return UserIO.getInstance().requestInputDialog(0, message, defaultmessage);
}
}
/**

View File

@ -57,7 +57,7 @@ public class CrptCm extends PluginForDecrypt {
state = 2;
} else if (br.containsHTML("Passwort:")) {
password = getUserInput("Folder PW", parameter);
password = getUserInput(null, parameter);
state = 3;
}

View File

@ -31,7 +31,6 @@ import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
import jd.utils.JDUtilities;
@ -64,7 +63,7 @@ public class CrptTo extends PluginForDecrypt {
Form captchaForm = null;
String passCode = null;
if (br.containsHTML("Passwort bitte hier")) {
passCode = Plugin.getUserInput("Password?", passCode, param);
passCode = getUserInput(null, param);
}
for (int i = 0; i < 5; i++) {
// Captcha handling

View File

@ -66,7 +66,7 @@ public class Crptngt extends PluginForDecrypt {
if (form == null) return null;
if (br.containsHTML("password to access this folder")) {
for (int i = 1; i <= 5; i++) {
String folderPass = getUserInput("Folder Password", param);
String folderPass = getUserInput(null, param);
form.put("opass", folderPass);
br.submitForm(form);
if (br.containsHTML("maximum number of password attempts")) throw new DecrypterException("You have entered the maximum number of password attempts");

View File

@ -64,7 +64,7 @@ public class CrpttCm extends PluginForDecrypt {
// String. else Request INstance
logger.info(br.loadConnection(con) + "");
if (br.containsHTML(PATTERN_PW)) {
String pass = getUserInput(JDL.L("plugins.hoster.general.passwordprotectedinput", "The links are protected by a password. Please enter the password:"), param.getDecrypterPassword(), param);
String pass = getUserInput(null, param);
String postData = "a=pw&pw=" + Encoding.urlEncode(pass);
br.postPage(parameter, postData);
if (br.containsHTML(PATTERN_PW)) {
@ -144,7 +144,7 @@ public class CrpttCm extends PluginForDecrypt {
pass = param.getDecrypterPassword();
for (int retrycounter = 1; retrycounter <= 5; retrycounter++) {
if (pass == null) {
pass = getUserInput(JDL.L("plugins.decrypt.cryptitcom.password", "Folder is password protected. Enter password:"), param.getDecrypterPassword(), param);
pass = getUserInput(null, param);
}
String post = "a=pw&pw=" + Encoding.urlEncode(pass);
br.setFollowRedirects(true);

View File

@ -132,15 +132,13 @@ public class FrShrdFldr extends PluginForDecrypt {
if (br.containsHTML("enter a password to access")) {
Form form = br.getFormbyProperty("name", "theForm");
if (form == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
String text = JDL.L("plugins.hoster.general.enterpassword", "Enter password:");
for (int retry = 5; retry > 0; retry--) {
pass = getUserInput(text, param);
pass = getUserInput(null, param);
form.put("userPass2", pass);
br.submitForm(form);
if (!br.containsHTML("enter a password to access"))
break;
else {
text = "(" + (retry - 1) + ") " + JDL.L("plugins.hoster.general.reenterpassword", "Wrong password. Please re-enter:");
if (retry == 1) {
logger.severe("Wrong Password!");
throw new DecrypterException("Wrong Password!");

View File

@ -25,7 +25,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
@ -51,7 +50,7 @@ public class KrM extends PluginForDecrypt {
for (int i = 0; i < 5; i++) {
if (form != null && form.hasInputFieldByName("key")) {
logger.info("pw protected link");
String password = Plugin.getUserInput(null, param);
String password = getUserInput(null, param);
form.put("key", password);
br.submitForm(form);
form = br.getForm(0);

View File

@ -26,7 +26,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
@ -51,7 +50,7 @@ public class KsRLCm extends PluginForDecrypt {
int flag = 0;
for (int i = 0; i < 5; i++) {
logger.info("pw protected link");
String password = Plugin.getUserInput(null, param);
String password = getUserInput(null, param);
String request = br.postPage("includes/ajax.php", "password=" + password + "&action=checkpassword");
flag = Integer.parseInt(new Regex(request, "\\['(\\d)','.*?'\\]").getMatch(0));
String url = new Regex(request, "\\['\\d','(.*?)'\\]").getMatch(0);

View File

@ -93,7 +93,7 @@ public class Lnksvn extends PluginForDecrypt {
for (int retry = 0; retry < 5; retry++) {
if (form == null) break;
if (form.containsHTML("besucherpasswort")) {
String pw = getUserInput(JDL.L("jd.plugins.decrypter.Lnksvn.pass", "Userpassword"), param);
String pw = getUserInput(null, param);
form.put("besucherpasswort", pw);
}
String url = "captcha/cap.php?hsh=" + form.getRegex("\\/captcha\\/cap\\.php\\?hsh=([^\"]+)").getMatch(0);

View File

@ -26,7 +26,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginForDecrypt;
import jd.utils.locale.JDL;
@ -62,7 +61,7 @@ public class PWProtectedRedirectorsDecrypter extends PluginForDecrypt {
for (int i = 0; i <= 2; i++) {
Form pwform = br.getForm(0);
if (pwform == null) return null;
String passCode = Plugin.getUserInput("Password?", param);
String passCode = getUserInput(null, param);
if (parameter.contains("urlaxe.net")) {
pwform.put("p", passCode);
} else if (parameter.contains("skracaj.org") || parameter.contains("l-x.pl")) {

View File

@ -26,7 +26,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginForDecrypt;
import jd.utils.locale.JDL;
@ -49,7 +48,7 @@ public class PdPsteCm extends PluginForDecrypt {
for (int i = 0; i <= 3; i++) {
Form pwform = br.getForm(0);
if (pwform == null) return null;
String passCode = Plugin.getUserInput("Password?", param);
String passCode = getUserInput(null, param);
pwform.put("pass", passCode);
br.submitForm(pwform);
if (br.containsHTML("name=\"pass\"")) continue;

View File

@ -30,7 +30,6 @@ import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.FilePackage;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
import jd.utils.locale.JDL;
@ -71,7 +70,7 @@ public class PrtcMyLnksCm extends PluginForDecrypt {
captchaForm.put("captcha", code);
if (br.containsHTML("Password :")) {
passCode = Plugin.getUserInput("Password?", param);
passCode = getUserInput(null, param);
captchaForm.put("passwd", passCode);
}
br.submitForm(captchaForm);

View File

@ -56,7 +56,7 @@ public class PrtctTOg extends PluginForDecrypt {
Form form = br.getForm(0);
InputField pass = form.getInputField("pass");
if (pass != null) {
pass.setValue(getUserInput("Besucherpasswort", param));
pass.setValue(getUserInput(null, param));
}
form.remove("captcha");

View File

@ -46,7 +46,7 @@ public class RlCtCm extends PluginForDecrypt {
for (int i = 0; i < 5; i++) {
br.getPage(page);
String linkid = br.getRegex("name=u value=\"(.*?)\"").getMatch(0);
String passwordstring = getUserInput(JDL.L("plugins.hoster.general.passwordprotectedinput", "The links are protected by a password. Please enter the password:"), param.getDecrypterPassword(), param);
String passwordstring = getUserInput(null, param);
br.postPage("http://urlcut.com/password.cgi", "u=" + linkid + "&p=" + Encoding.urlEncode(passwordstring));
page = null;
page = br.getRedirectLocation();

View File

@ -30,7 +30,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginForDecrypt;
@DecrypterPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "rapidsafe.de" }, urls = { "http://.+rapidsafe\\.de" }, flags = { 0 })
@ -65,7 +64,7 @@ public class RpdsfD extends PluginForDecrypt {
String[] pwDat = pw.getRow(0);
String post = pwDat[0] + pwDat[1];
if (pass == null) pass = Plugin.getUserInput("Password?", param);
if (pass == null) pass = getUserInput(null, param);
br.postPage(parameter, post + pass.trim());

View File

@ -31,7 +31,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
import jd.plugins.PluginForHost;
@ -66,7 +65,7 @@ public class SflnkgNt extends PluginForDecrypt {
capForm.setAction(parameter);
for (int i = 0; i <= 5; i++) {
if (br.containsHTML(PASSWORDPROTECTEDTEXT)) {
capForm.put("link-password", Plugin.getUserInput("Password?", param));
capForm.put("link-password", getUserInput(null, param));
}
if (br.containsHTML(RECAPTCHATEXT)) {
PluginForHost recplug = JDUtilities.getPluginForHost("DirectHTTP");

View File

@ -45,7 +45,6 @@ import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
import jd.utils.JDUtilities;
@ -145,7 +144,7 @@ public class ShrLnksBz extends PluginForDecrypt {
// First try the stored password, if that doesn't work, ask the
// user to enter it
if (latestPassword == null) latestPassword = Plugin.getUserInput("Password " + getHost() + "?", param);
if (latestPassword == null) latestPassword = getUserInput(null, param);
pwform.put("password", latestPassword);
br.submitForm(pwform);
//

View File

@ -29,7 +29,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginForDecrypt;
import jd.utils.locale.JDL;
@ -70,7 +69,7 @@ public class SprdLnkUs extends PluginForDecrypt {
for (int i = 0; i < 5; i++) {
String sendData = "http://spreadlink.us/index.php?request=datei&datei=weiterleitung&link=" + linkid + "&action=1";
if (!passwordOrNot.equals("1")) {
String thePassword = Plugin.getUserInput("Password?", param);
String thePassword = getUserInput(null, param);
sendData = sendData + "&passwort=" + thePassword;
}
if (captchaOrNot.equals("1")) {

View File

@ -33,7 +33,6 @@ import jd.plugins.PluginForDecrypt;
import jd.plugins.PluginForHost;
import jd.plugins.hoster.DirectHTTP;
import jd.utils.JDUtilities;
import jd.utils.locale.JDL;
@DecrypterPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "stealth.to" }, urls = { "http://[\\w\\.]*?stealth\\.to/(\\?id\\=[\\w]+|index\\.php\\?id\\=[\\w]+|\\?go\\=captcha&id=[\\w]+)|http://[\\w\\.]*?stealth\\.to/folder/[\\w]+" }, flags = { 0 })
public class Stlth extends PluginForDecrypt {
@ -60,7 +59,7 @@ public class Stlth extends PluginForDecrypt {
if (br.containsHTML("besucherpass.png")) {
Form form = br.getFormBySubmitvalue("Weiter");
form.put("access_pass", getUserInput(JDL.LF("jd.plugins.decrypter.stealth.askpassword", "Downloadpassword required for %s", param.getCryptedUrl()), param));
form.put("access_pass", getUserInput(null, param));
br.submitForm(form);
}

View File

@ -27,7 +27,6 @@ import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
import jd.utils.locale.JDL;
@ -66,7 +65,7 @@ public class StrPrtctNet extends PluginForDecrypt {
}
if (br.containsHTML("Passwort")) {
String passCode = null;
passCode = Plugin.getUserInput("Password?", param);
passCode = getUserInput(null, param);
captchaForm.put("txtPassword", passCode);
}
br.submitForm(captchaForm);

View File

@ -27,7 +27,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginForDecrypt;
import jd.utils.locale.JDL;
@ -53,7 +52,7 @@ public class Tnypst extends PluginForDecrypt {
if (id == null) id = new Regex(link, "tinypaste\\.com/([0-9a-z]+)").getMatch(0);
Form pwform = br.getForm(0);
if (pwform == null || id == null) return null;
String pw = Plugin.getUserInput("Password?", parameter);
String pw = getUserInput(null, parameter);
pwform.put("password_" + id, pw);
br.submitForm(pwform);
if (br.containsHTML("(Enter the correct password|has been password protected)")) continue;

View File

@ -30,7 +30,6 @@ import jd.plugins.CryptedLink;
import jd.plugins.DecrypterException;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForDecrypt;
import jd.utils.JDUtilities;
@ -78,7 +77,7 @@ public class UlCrptCm extends PluginForDecrypt {
}
// Password handling
if (br.containsHTML("geben Sie bitte jetzt das Passwort ein")) {
passCode = Plugin.getUserInput("Password?", param);
passCode = getUserInput(null, param);
captchaForm.put("strPassword", passCode);
}
br.submitForm(captchaForm);

View File

@ -24,7 +24,6 @@ import jd.controlling.ProgressController;
import jd.plugins.CryptedLink;
import jd.plugins.DecrypterPlugin;
import jd.plugins.DownloadLink;
import jd.plugins.Plugin;
import jd.plugins.PluginForDecrypt;
@DecrypterPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "xenonlink.net" }, urls = { "http://[\\w\\.]*?xenonlink\\.net/" }, flags = { 0 })
@ -34,11 +33,10 @@ public class XnnLnkNt extends PluginForDecrypt {
super(wrapper);
}
// @Override
public ArrayList<DownloadLink> decryptIt(CryptedLink param, ProgressController progress) throws Exception {
ArrayList<DownloadLink> decryptedLinks = new ArrayList<DownloadLink>();
String dataCode = Plugin.getUserInput("Data-Code?", param);
String dataCode = getUserInput(null, param);
br.getPage("http://www.xenonlink.net/index.php?p=2&dg=" + dataCode);
@ -49,6 +47,4 @@ public class XnnLnkNt extends PluginForDecrypt {
return decryptedLinks;
}
// @Override
}

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "allshares.ge" }, urls = { "http://[\\w\\.]*?allshares\\.ge/(\\?d|download\\.php\\?id)=[A-Z0-9]+" }, flags = { 0 })
public class AllSharesGe extends PluginForHost {
@ -99,7 +98,7 @@ public class AllSharesGe extends PluginForHost {
if (captchaform == null || !br.containsHTML("captcha.php")) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML("downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */

View File

@ -22,12 +22,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "axifile.com" }, urls = { "http://[\\w\\.]*?axifile\\.com/(\\?|mydownload\\.php\\?file=)\\d+" }, flags = { 0 })
public class AxiFileCom extends PluginForHost {
@ -73,7 +72,7 @@ public class AxiFileCom extends PluginForHost {
Form pwform = br.getForm(0);
if (pwform == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -26,12 +26,11 @@ import jd.nutils.encoding.Encoding;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "azsharing.com" }, urls = { "http://[\\w\\.]*?azsharing\\.com/[a-z0-9]{12}/" }, flags = { 0 })
@ -222,7 +221,7 @@ public class AzSharingCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -243,7 +242,7 @@ public class AzSharingCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -67,9 +67,7 @@ public class BadongoCom extends PluginForHost {
if (pwForm == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
String pass = downloadLink.getDecrypterPassword();
if (pass == null) {
String passDlgMsg = JDL.L("plugins.hoster.general.enterpassword", "Enter password:");
if (i > 0) passDlgMsg = JDL.L("plugins.hoster.general.reenterpassword", "Wrong password. Please re-enter:");
pass = getUserInput(passDlgMsg, downloadLink);
pass = getUserInput(null, downloadLink);
if (pass == null) continue;
}
pwForm.put("pwd", pass);

View File

@ -31,12 +31,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "banashare.com" }, urls = { "http://[\\w\\.]*?banashare\\.com/[a-z0-9]{12}" }, flags = { 2 })
@ -241,7 +240,7 @@ public class BanaShareCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -262,7 +261,7 @@ public class BanaShareCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -433,7 +432,7 @@ public class BanaShareCom extends PluginForHost {
if (DLForm == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (brbefore.contains("<b>Passwort:</b>|<b>Password:</b>")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "bebasupload.com" }, urls = { "http://[\\w\\.]*?bebasupload\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -235,7 +234,7 @@ public class BebasUploadCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -256,7 +255,7 @@ public class BebasUploadCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "bigfile.in" }, urls = { "http://[\\w\\.]*?bigfile\\.in/[a-z0-9]{12}" }, flags = { 0 })
@ -290,7 +289,7 @@ public class BigFileIn extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -30,12 +30,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "biggerupload.com" }, urls = { "http://[\\w\\.]*?biggerupload\\.com/[a-z0-9]{12}" }, flags = { 2 })
@ -155,7 +154,7 @@ public class BiggeruploadCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -177,7 +176,7 @@ public class BiggeruploadCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -359,7 +358,7 @@ public class BiggeruploadCom extends PluginForHost {
if (DLForm == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML(passwordText)) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "bin.ge" }, urls = { "http://[\\w\\.]*?bin\\.ge/((\\?d|download\\.php\\?id)=[A-Z0-9]+|((en|ru|fr|es)/)?file/[0-9]+/)" }, flags = { 0 })
public class BinGe extends PluginForHost {
@ -98,7 +97,7 @@ public class BinGe extends PluginForHost {
}
if (br.containsHTML("class=textinput name=downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "cash-file.com" }, urls = { "http://[\\w\\.]*?cash-file\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -264,7 +263,7 @@ public class CashFileCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -30,12 +30,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "combozip.com" }, urls = { "http://[\\w\\.]*?combozip\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -421,7 +420,7 @@ public class ComboZipCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -28,17 +28,16 @@ import jd.http.RandomUserAgent;
import jd.nutils.encoding.Encoding;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.parser.html.Form.MethodType;
import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "cramit.in" }, urls = { "http://[\\w\\.]*?(cramit\\.in|cramitin\\.net)/[a-z0-9]{12}" }, flags = { 2 })
@ -220,7 +219,7 @@ public class CraMitIn extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -251,7 +250,7 @@ public class CraMitIn extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -481,7 +480,7 @@ public class CraMitIn extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "data-loading.com" }, urls = { "http://[\\w\\.]*?data-loading\\.com/.{2}/file/\\d+/\\w+" }, flags = { 2 })
public class DataLoadingCom extends PluginForHost {
@ -135,7 +134,7 @@ public class DataLoadingCom extends PluginForHost {
Form pwform = br.getFormbyProperty("name", "myform");
if (pwform == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (parameter.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", parameter);
passCode = getUserInput(null, parameter);
} else {
/* gespeicherten PassCode holen */
passCode = parameter.getStringProperty("pass", null);
@ -199,8 +198,7 @@ public class DataLoadingCom extends PluginForHost {
if (captchaform == null || !br.containsHTML("captcha.php")) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML("downloadpw")) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -227,7 +225,7 @@ public class DataLoadingCom extends PluginForHost {
Form pwform = br.getFormbyProperty("name", "myform");
if (pwform == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -33,12 +33,12 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "depositfiles.com" }, urls = { "http://[\\w\\.]*?depositfiles\\.com(/\\w{1,3})?/files/[\\w]+" }, flags = { 2 })
@ -106,7 +106,7 @@ public class DepositFiles extends PluginForHost {
if (br.containsHTML("\"file_password\"")) {
logger.info("This file seems to be password protected.");
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "digisofts.net" }, urls = { "http://[\\w\\.]*?digisofts\\.net/[a-z0-9]{12}" }, flags = { 0 })
@ -200,7 +199,7 @@ public class DigiSoftsNet extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -221,7 +220,7 @@ public class DigiSoftsNet extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -34,12 +34,12 @@ import jd.nutils.encoding.Encoding;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
/**
@ -48,6 +48,7 @@ import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "DirectHTTP", "http links" }, urls = { "directhttp://.+", "https?viajd://[\\d\\w\\.:\\-@]*/.*\\.(3gp|7zip|7z|abr|ac3|ai|aiff|aif|aifc|au|avi|bin|bz2|cbr|cbz|ccf|cue|deb|divx|djvu|dlc|dmg|doc|docx|dot|eps|exe|ff|flv|f4v|gif|gz|iwd|iso|java|jar|jpg|jpeg|jdeatme|load|m4v|m4a|mkv|mp2|mp3|mp4|mov|movie|mpeg|mpe|mpg|msi|msu|nfo|oga|ogg|ogv|otrkey|pkg|png|pdf|ppt|pptx|pps|ppz|pot|psd|qt|rmvb|rar|rnd|r\\d+|rpm|run|rsdf|rtf|sh|srt|snd|sfv|swf|tar|tif|tiff|ts|txt|viv|vivo|vob|wav|wmv|xla|xls|xpi|zip|z\\d+|_[_a-z]{2}|\\d+)" }, flags = { 0, 0 })
public class DirectHTTP extends PluginForHost {
private static final String JDL_PREFIX = "jd.plugins.hoster.DirectHTTP.";
public static final String ENDINGS = "\\.(3gp|7zip|7z|abr|ac3|ai|aiff|aif|aifc|au|avi|bin|bz2|cbr|cbz|ccf|cue|deb|divx|djvu|dlc|dmg|doc|docx|dot|eps|exe|ff|flv|f4v|gif|gz|iwd|iso|java|jar|jpg|jpeg|jdeatme|load|m4v|m4a|mkv|mp2|mp3|mp4|mov|movie|mpeg|mpe|mpg|msi|msu|nfo|oga|ogg|ogv|otrkey|pkg|png|pdf|ppt|pptx|pps|ppz|pot|psd|qt|rmvb|rar|rnd|r\\d+|rpm|run|rsdf|rtf|sh|srt|snd|sfv|swf|tar|tif|tiff|ts|txt|viv|vivo|vob|wav|wmv|xla|xls|xpi|zip|z\\d+|_[_a-z]{2}|\\d+)";
public static final String NORESUME = "nochunkload";
@ -104,11 +105,17 @@ public class DirectHTTP extends PluginForHost {
}
private String getBasicAuth(DownloadLink link) {
String url;
if (link.getLinkType() == DownloadLink.LINKTYPE_CONTAINER) {
url = link.getHost();
} else {
url = link.getBrowserUrl();
}
String username = null;
String password = null;
try {
username = getUserInput("Username(BasicAuth)", link);
password = getUserInput("Password(BasicAuth)", link);
username = getUserInput(JDL.LF(JDL_PREFIX + "username", "Username (BasicAuth) for %s", url), link);
password = getUserInput(JDL.LF(JDL_PREFIX + "password", "Password (BasicAuth) for %s", url), link);
} catch (Exception e) {
return null;
}

View File

@ -23,13 +23,13 @@ import jd.http.URLConnectionAdapter;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.PluginUtils;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "divshare.com" }, urls = { "http://[\\w\\.]*?divshare\\.com/(download|image|direct)/\\d+-.+" }, flags = { 0 })
public class DivShareCom extends PluginForHost {
@ -65,8 +65,7 @@ public class DivShareCom extends PluginForHost {
if (form == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
String passCode = null;
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -23,12 +23,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "divxden.com" }, urls = { "http://[\\w\\.]*?divxden\\.com/[a-z0-9]{12}" }, flags = { 0 })
public class DivxDenCom extends PluginForHost {
@ -163,7 +162,7 @@ public class DivxDenCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "dll.bz" }, urls = { "http://[\\w\\.]*?dll\\.bz/((\\?d|download\\.php\\?id)=[A-Z0-9]+|((en|ru|fr|es)/)?file/[0-9]+/)" }, flags = { 0 })
public class DllBz extends PluginForHost {
@ -87,8 +86,7 @@ public class DllBz extends PluginForHost {
}
if (br.containsHTML("class=textinput name=downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "dodajto.eu" }, urls = { "http://[\\w\\.]*?dodajto\\.eu/file/[0-9]+/" }, flags = { 0 })
public class DodajtoEu extends PluginForHost {
@ -99,8 +98,7 @@ public class DodajtoEu extends PluginForHost {
if (br.containsHTML("downloadpw")) {
if (br.containsHTML("downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "eeeshare.com" }, urls = { "http://[\\w\\.]*?eeeshare\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -291,7 +290,7 @@ public class EeeShareCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -30,12 +30,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "enterupload.com" }, urls = { "http://[\\w\\.]*?enterupload\\.com/[a-z0-9]{12}" }, flags = { 2 })
@ -159,7 +158,7 @@ public class EnteruploadCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -180,7 +179,7 @@ public class EnteruploadCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -334,7 +333,7 @@ public class EnteruploadCom extends PluginForHost {
if (DLForm == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML("(<br><b>Password:</b> <input|<br><b>Passwort:</b> <input)")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "fast-host.ch" }, urls = { "http://[\\w\\.]*?fast-host\\.ch/[a-z0-9]{12}" }, flags = { 0 })
@ -264,7 +263,7 @@ public class FastHostCh extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -26,12 +26,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "file2box.com" }, urls = { "http://[\\w\\.]*?file2box\\.(com|net)/[a-z0-9]{12}" }, flags = { 0 })
public class File2BoxCom extends PluginForHost {
@ -172,7 +171,7 @@ public class File2BoxCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -25,12 +25,11 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "file2upload.net" }, urls = { "http://[\\w\\.]*?file2upload\\.(net|com)/download/[0-9]+/" }, flags = { 2 })
public class File2UploadDotNet extends PluginForHost {
@ -93,7 +92,7 @@ public class File2UploadDotNet extends PluginForHost {
}
if (br.containsHTML("Enter password to download this file")) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -154,7 +153,7 @@ public class File2UploadDotNet extends PluginForHost {
}
if (br.containsHTML("Enter password to download this file")) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "file4save.com" }, urls = { "http://[\\w\\.]*?file4save\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -264,7 +263,7 @@ public class File4SaveCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -27,12 +27,12 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "file-bit.net" }, urls = { "http://[\\w\\.]*?file-bit\\.net/[a-z0-9]{12}" }, flags = { 0 })
@ -215,7 +215,7 @@ public class FileBitNet extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filebling.com" }, urls = { "http://[\\w\\.]*?filebling\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -256,7 +255,7 @@ public class FileBlingCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filecatch.net" }, urls = { "http://[\\w\\.]*?filecatch\\.net/[a-z0-9]{12}" }, flags = { 0 })
@ -237,7 +236,7 @@ public class FileCatchNet extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -258,7 +257,7 @@ public class FileCatchNet extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filechip.com" }, urls = { "http://[\\w\\.]*?filechip\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -199,7 +198,7 @@ public class FileChipCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -220,7 +219,7 @@ public class FileChipCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -25,12 +25,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filegiga.com" }, urls = { "http://[\\w\\.]*?filegiga\\.com/[a-z0-9]{12}" }, flags = { 0 })
public class FileGigaCom extends PluginForHost {
@ -196,7 +195,7 @@ public class FileGigaCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filekeeping.de" }, urls = { "http://[\\w\\.]*?filekeeping\\.de/((\\?d|download\\.php\\?id)=[A-Z0-9]+|((en|ru|fr|es)/)?file/[0-9]+/)" }, flags = { 0 })
public class FileKeepingDe extends PluginForHost {
@ -97,8 +96,7 @@ public class FileKeepingDe extends PluginForHost {
}
if (br.containsHTML("class=textinput name=downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "fileplanet.com.ua" }, urls = { "http://[\\w\\.]*?fileplanet\\.com\\.ua/[a-z0-9]{12}" }, flags = { 0 })
@ -289,7 +288,7 @@ public class FilePlanetComUa extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "fileplayground.com" }, urls = { "http://[\\w\\.]*?fileplayground\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -285,7 +284,7 @@ public class FilePlayGroundCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "file-share.cc" }, urls = { "http://[\\w\\.]*?file-share\\.cc/[a-z0-9]{12}" }, flags = { 0 })
@ -285,7 +284,7 @@ public class FileShareCc extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -29,12 +29,11 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filesonic.com" }, urls = { "http://[\\w\\.]*?(sharingmatrix|filesonic)\\.com/.*?file/([0-9]+(/.+)?|[a-z0-9]+/[0-9]+(/.+)?)" }, flags = { 2 })
@ -192,7 +191,7 @@ public class FileSonicCom extends PluginForHost {
if (br.containsHTML("This file is password protected")) {
/* password handling */
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(JDL.L("plugins.hoster.sharingmatrixcom.password", "Password?"), downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* get saved password */
passCode = downloadLink.getStringProperty("pass", null);
@ -271,7 +270,7 @@ public class FileSonicCom extends PluginForHost {
if (br.containsHTML("This file is password protected")) {
/* password handling */
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(JDL.L("plugins.hoster.sharingmatrixcom.password", "Password?"), downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filestab.com" }, urls = { "http://[\\w\\.]*?filestab\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -268,7 +267,7 @@ public class FileStabCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filestock.ru" }, urls = { "http://[\\w\\.]*?filestock\\.ru/[a-z0-9]{12}" }, flags = { 0 })
@ -231,7 +230,7 @@ public class FileStockRu extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -252,7 +251,7 @@ public class FileStockRu extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filestore.com.ua" }, urls = { "http://[\\w\\.]*?filestore\\.com\\.ua/\\?d=[A-Z0-9]+" }, flags = { 0 })
public class FileStoreComUa extends PluginForHost {
@ -68,8 +67,7 @@ public class FileStoreComUa extends PluginForHost {
if (captchaform == null || !br.containsHTML("captcha.php")) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML("downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -20,12 +20,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filesurf.ru" }, urls = { "http://[\\w\\.]*?(filesurf|4ppl|files\\.youmama|upload\\.xradio)\\.ru/[0-9]+" }, flags = { 0 })
public class FileSurfRu extends PluginForHost {
@ -66,7 +65,7 @@ public class FileSurfRu extends PluginForHost {
if (captchaForm == null || captchaid == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML("password")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -31,12 +31,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filevo.com" }, urls = { "http://[\\w\\.]*?filevo\\.com/[a-z0-9]{12}\\.html" }, flags = { 2 })
@ -391,7 +390,7 @@ public class FileVoCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -23,12 +23,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "filescloud.com" }, urls = { "http://[\\w\\.]*?filescloud\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -168,7 +167,7 @@ public class FilesCloudCom extends PluginForHost {
c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -187,7 +186,7 @@ public class FilesCloudCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "files.ge" }, urls = { "http://[\\w\\.]*?files\\.ge/((\\?d|download\\.php\\?id)=[A-Z0-9]+|((en|ru|fr|es)/)?file/[0-9]+/)" }, flags = { 0 })
public class FilesGe extends PluginForHost {
@ -101,7 +100,7 @@ public class FilesGe extends PluginForHost {
}
if (br.containsHTML("class=textinput name=downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "flowhot.info" }, urls = { "http://[\\w\\.]*?flowhot\\.info/[a-z0-9]{12}" }, flags = { 0 })
@ -264,7 +263,7 @@ public class FlowHotInfo extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -26,12 +26,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "fofly.com" }, urls = { "http://[\\w\\.]*?fofly\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -196,7 +195,7 @@ public class FoFlyCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -218,7 +217,7 @@ public class FoFlyCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -19,12 +19,11 @@ package jd.plugins.hoster;
import jd.PluginWrapper;
import jd.parser.Regex;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "4share.ws" }, urls = { "http://[\\w\\.]*?4share\\.ws/file/.*?/.{1}" }, flags = { 0 })
public class FourShareWs extends PluginForHost {
@ -62,7 +61,7 @@ public class FourShareWs extends PluginForHost {
if (br.containsHTML("(File Is Protected|Enter password to continue)")) {
for (int i = 0; i <= 3; i++) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
//http://www.4shared.com/file/<FILEID[a-70-9]>/<FILENAME>.html
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "4shared.com" }, urls = { "http://[\\w\\.]*?4shared(-china)?\\.com/(account/)?(get|file|document|photo|video|audio)/.+?/.*" }, flags = { 2 })
@ -97,9 +96,8 @@ public class FourSharedCom extends PluginForHost {
if (br.containsHTML("enter a password to access")) downloadLink.setDecrypterPassword(null);
}
if (downloadLink.getDecrypterPassword() == null) {
String text = JDL.L("plugins.hoster.general.enterpassword", "Enter password:");
for (int retry = 5; retry > 0; retry--) {
String pass = getUserInput(text, downloadLink);
String pass = getUserInput(null, downloadLink);
form.put("userPass2", pass);
br.submitForm(form);
if (!br.containsHTML("enter a password to access")) {
@ -107,7 +105,6 @@ public class FourSharedCom extends PluginForHost {
downloadLink.setDecrypterPassword(pass);
break;
} else {
text = "(" + (retry - 1) + ") " + JDL.L("plugins.hoster.general.reenterpassword", "Wrong password. Please re-enter:");
if (retry == 1) logger.severe("Wrong Password!");
}
}
@ -187,7 +184,7 @@ public class FourSharedCom extends PluginForHost {
Form form = br.getFormbyProperty("name", "theForm");
if (form == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (pass == null) pass = getUserInput("Password?", downloadLink);
if (pass == null) pass = getUserInput(null, downloadLink);
form.put("userPass2", pass);
dl = jd.plugins.BrowserAdapter.openDownload(br, downloadLink, form, false, 1);
if (br.containsHTML("enter a password to access")) {

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "4us.to" }, urls = { "http://[\\w\\.]*?4us\\.to/download\\.php\\?id=[A-Z0-9]+" }, flags = { 0 })
public class FourUsTo extends PluginForHost {
@ -96,8 +95,7 @@ public class FourUsTo extends PluginForHost {
}
if (br.containsHTML("class=textinput name=downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "gotupload.com" }, urls = { "http://[\\w\\.]*?gotupload\\.com/[a-z|0-9]+" }, flags = { 0 })
@ -196,7 +195,7 @@ public class GotUploadCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -217,7 +216,7 @@ public class GotUploadCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -31,12 +31,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "hatlimit.com" }, urls = { "http://[\\w\\.]*?hatlimit\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -384,7 +383,7 @@ public class HatLimitCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -21,12 +21,11 @@ import java.io.IOException;
import jd.PluginWrapper;
import jd.parser.Regex;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "host.hackerbox.org" }, urls = { "http://[\\w\\.]*?host\\.hackerbox\\.org/download\\.php\\?file=[a-z0-9]+" }, flags = { 0 })
public class HostHackerboxOrg extends PluginForHost {
@ -81,7 +80,7 @@ public class HostHackerboxOrg extends PluginForHost {
public String handlePassword(String passCode, DownloadLink downloadLink) throws IOException, PluginException {
for (int i = 0; i <= 3; i++) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "hostingcup.com" }, urls = { "http://www\\.hostingcup\\.com/[0-9a-zA-Z]{12}" }, flags = { 2 })
@ -239,7 +238,7 @@ public class HostingcupCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -30,12 +30,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "hulkshare.com" }, urls = { "http://[\\w\\.]*?hulkshare\\.com/[a-z0-9]{12}" }, flags = { 2 })
@ -198,7 +197,7 @@ public class HulkShareCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -219,7 +218,7 @@ public class HulkShareCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -375,7 +374,7 @@ public class HulkShareCom extends PluginForHost {
if (DLForm == null) throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
if (br.containsHTML("(<br><b>Passwort:</b>|<br><b>Password:</b>)")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */
passCode = link.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "ifolder.ru" }, urls = { "http://([\\w.-]*?\\.)?(ifolder\\.ru|files\\.metalarea\\.org)/\\d+" }, flags = { 0 })
@ -153,7 +152,7 @@ public class IfolderRu extends PluginForHost {
throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);
}
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "imzupload.com" }, urls = { "http://[\\w\\.]*?imzupload\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -196,7 +195,7 @@ public class ImzUploadCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -217,7 +216,7 @@ public class ImzUploadCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -23,12 +23,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "jumbofiles.com" }, urls = { "http://[\\w\\.]*?jumbofiles\\.com/[0-9a-z]+{12}" }, flags = { 2 })
public class JumboFilesCom extends PluginForHost {
@ -84,7 +83,7 @@ public class JumboFilesCom extends PluginForHost {
String passCode = null;
if (brbefore.contains("<b>Password:</b>")) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -31,12 +31,11 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "keepfile.com" }, urls = { "http://[\\w\\.]*?keepfile\\.com/[a-z0-9]{12}" }, flags = { 2 })
@ -393,7 +392,7 @@ public class KeepFileCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -22,12 +22,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "link.ge" }, urls = { "http://[\\w\\.]*?link\\.ge/((\\?d|download\\.php\\?id)=[A-Z0-9]+|((en|ru|fr|es)/)?file/[0-9]+/)" }, flags = { 0 })
public class LinkGe extends PluginForHost {
@ -98,7 +97,7 @@ public class LinkGe extends PluginForHost {
}
if (br.containsHTML("class=textinput name=downloadpw")) {
if (link.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", link);
passCode = getUserInput(null, link);
} else {
/* gespeicherten PassCode holen */

View File

@ -27,12 +27,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "linkzhost.com" }, urls = { "http://[\\w\\.]*?linkzhost\\.com/[a-z0-9]{12}" }, flags = { 0 })
@ -198,7 +197,7 @@ public class LinkzHostCom extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);
@ -219,7 +218,7 @@ public class LinkzHostCom extends PluginForHost {
if (recaptcha == false) {
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.Regex;
import jd.parser.html.Form;
import jd.parser.html.HTMLParser;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "lizshare.net" }, urls = { "http://[\\w\\.]*?lizshare\\.net/[a-z0-9]{12}" }, flags = { 0 })
@ -258,7 +257,7 @@ public class LizShareCom extends PluginForHost {
public String handlePassword(String passCode, Form pwform, DownloadLink thelink) throws IOException, PluginException {
if (thelink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", thelink);
passCode = getUserInput(null, thelink);
} else {
/* gespeicherten PassCode holen */
passCode = thelink.getStringProperty("pass", null);

View File

@ -30,12 +30,12 @@ import jd.parser.html.HTMLParser;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.JDUtilities;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "loadfiles.in" }, urls = { "http://[\\w\\.]*?loadfiles\\.in/[a-z0-9]{12}" }, flags = { 2 })
@ -200,7 +200,7 @@ public class LoadFilesIn extends PluginForHost {
String c = getCaptchaCode(cf, downloadLink);
if (password == true) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput("Password?", downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -38,12 +38,12 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "megaporn.com" }, urls = { "http://[\\w\\.]*?(megaporn|megarotic|sexuploader)\\.com/.*?(\\?|&)d=[\\w]+" }, flags = { 2 })
@ -295,9 +295,9 @@ public class MegaPornCom extends PluginForHost {
// User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)
// Content-Length: 12
// Content-Type: application/x-www-form-urlencoded
//
//
// this.setBrowserExclusive();
//
//
br.getHeaders().clear();
br.getHeaders().setDominant(true);
@ -487,7 +487,7 @@ public class MegaPornCom extends PluginForHost {
try {
String passCode;
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -31,22 +31,22 @@ import jd.config.ConfigEntry;
import jd.controlling.AccountController;
import jd.controlling.JDLogger;
import jd.http.Browser;
import jd.http.Browser.BrowserException;
import jd.http.RandomUserAgent;
import jd.http.Request;
import jd.http.URLConnectionAdapter;
import jd.http.Browser.BrowserException;
import jd.nutils.encoding.Encoding;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "megaupload.com" }, urls = { "http://[\\w\\.]*?(megaupload)\\.com/.*?(\\?|&)d=[0-9A-Za-z]+" }, flags = { 2 })
@ -737,7 +737,7 @@ public class Megauploadcom extends PluginForHost {
try {
String passCode;
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -28,12 +28,11 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
import org.mozilla.javascript.Context;
@ -227,7 +226,7 @@ public class ShareOnlineBiz extends PluginForHost {
if (form.containsHTML("name=downloadpw")) {
String passCode = null;
if (parameter.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, parameter);
passCode = getUserInput(null, parameter);
} else {
/* gespeicherten PassCode holen */
passCode = parameter.getStringProperty("pass", null);
@ -285,7 +284,7 @@ public class ShareOnlineBiz extends PluginForHost {
String passCode = null;
if (form.containsHTML("name=downloadpw")) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -23,12 +23,11 @@ import jd.PluginWrapper;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "2shared.com" }, urls = { "http://[\\w\\.]*?2shared\\.com/(audio|file|video)/.*?/[a-zA-Z0-9._]+" }, flags = { 0 })
@ -76,7 +75,7 @@ public class TwoSharedCom extends PluginForHost {
if (pwform != null) {
String passCode;
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
passCode = downloadLink.getStringProperty("pass", null);
}

View File

@ -31,12 +31,11 @@ import jd.parser.html.Form;
import jd.plugins.Account;
import jd.plugins.AccountInfo;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "uploaded.to" }, urls = { "(http://[\\w\\.]*?uploaded\\.to/.*?(file/|\\?id=|&id=)[\\w]+/?)|(http://[\\w\\.]*?ul\\.to/[\\w\\-]+/.+)|(http://[\\w\\.]*?ul\\.to/[\\w\\-]+/?)" }, flags = { 2 })
@ -307,7 +306,7 @@ public class Uploadedto extends PluginForHost {
if (form != null && form.hasInputFieldByName("file_key")) {
logger.info("pw protected link");
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -23,12 +23,11 @@ import jd.http.RandomUserAgent;
import jd.parser.Regex;
import jd.parser.html.Form;
import jd.plugins.DownloadLink;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.plugins.HostPlugin;
import jd.plugins.LinkStatus;
import jd.plugins.Plugin;
import jd.plugins.PluginException;
import jd.plugins.PluginForHost;
import jd.plugins.DownloadLink.AvailableStatus;
import jd.utils.locale.JDL;
@HostPlugin(revision = "$Revision$", interfaceVersion = 2, names = { "xup.in" }, urls = { "http://[\\w\\.]*?xup\\.(in/dl,\\d+/?.+?|raidrush\\.ws/ndl_[a-z0-9]+)" }, flags = { 0 })
@ -76,7 +75,7 @@ public class XupIn extends PluginForHost {
String passCode = null;
if (download.hasInputFieldByName("vpass")) {
if (downloadLink.getStringProperty("pass", null) == null) {
passCode = Plugin.getUserInput(null, downloadLink);
passCode = getUserInput(null, downloadLink);
} else {
/* gespeicherten PassCode holen */
passCode = downloadLink.getStringProperty("pass", null);

View File

@ -65,9 +65,7 @@ import jd.nutils.Formatter;
import jd.nutils.OSDetector;
import jd.nutils.io.JDIO;
import jd.parser.Regex;
import jd.plugins.CryptedLink;
import jd.plugins.DownloadLink;
import jd.plugins.LinkStatus;
import jd.plugins.PluginForDecrypt;
import jd.plugins.PluginForHost;
import jd.plugins.PluginsC;
@ -229,40 +227,6 @@ public class JDUtilities {
return null;
}
public static String getUserInput(final String message, final DownloadLink link) {
return getUserInput(message, null, link);
}
public static String getUserInput(final String message, final String defaultmessage, final DownloadLink link) {
try {
link.getLinkStatus().addStatus(LinkStatus.WAITING_USERIO);
link.requestGuiUpdate();
final String code = getUserInput(message, defaultmessage);
link.requestGuiUpdate();
return code;
} finally {
link.getLinkStatus().removeStatus(LinkStatus.WAITING_USERIO);
}
}
public static String getUserInput(final String message, final CryptedLink link) {
return getUserInput(message, null, link);
}
public static String getUserInput(final String message, final String defaultmessage, final CryptedLink link) {
link.getProgressController().setStatusText(JDL.L("gui.linkgrabber.waitinguserio", "Waiting for user input"));
final String password = getUserInput(message, defaultmessage);
link.getProgressController().setStatusText(null);
return password;
}
public static String getUserInput(final String message, final String defaultmessage) {
synchronized (USERIO_LOCK) {
return UserIO.getInstance().requestInputDialog(0, message == null ? JDL.L("gui.linkgrabber.password", "Password?") : message, defaultmessage == null ? "" : defaultmessage);
}
}
/**
* @return Configuration instanz
*/