Note: This patch isn't finished. When this patch is applied, you won't be able to log in with libsl with a password at all, because the patch needs more work to actually leave the password parameter out of the xmlrpc request.
Index: libsecondlife/Login.cs
===================================================================
--- libsecondlife/Login.cs (revision 1490)
+++ libsecondlife/Login.cs (working copy)
@@ -101,6 +101,8 @@
///
public string Password;
///
+ public string WebLoginKey;
+ ///
public string Start;
///
public string Channel;
@@ -455,6 +457,8 @@
CurrentContext.Params.MAC = String.Empty;
if (CurrentContext.Params.Channel == null)
CurrentContext.Params.Channel = String.Empty;
+ if (CurrentContext.Params.Password == null)
+ CurrentContext.Params.Password = String.Empty;
// Convert the password to MD5 if it isn't already
if (CurrentContext.Params.Password.Length != 35 && !CurrentContext.Params.Password.StartsWith("$1$"))
@@ -473,6 +477,7 @@
loginParams.first = CurrentContext.Params.FirstName;
loginParams.last = CurrentContext.Params.LastName;
loginParams.passwd = CurrentContext.Params.Password;
+ loginParams.web_login_key = CurrentContext.Params.WebLoginKey;
loginParams.start = CurrentContext.Params.Start;
loginParams.channel = CurrentContext.Params.Channel;
loginParams.version = CurrentContext.Params.Version;
@@ -798,6 +803,7 @@
public string first;
public string last;
public string passwd;
+ public string web_login_key;
public string start;
public string channel;
public string version;
Index: libsecondlife/examples/TestClient/Program.cs
===================================================================
--- libsecondlife/examples/TestClient/Program.cs (revision 1490)
+++ libsecondlife/examples/TestClient/Program.cs (working copy)
@@ -116,6 +116,16 @@
accounts.Add(account);
}
+ else if (arguments["first"] != null && arguments["last"] != null && arguments["loginkey"] != null)
+ {
+ // Taking a single login off the command-line
+ account = new LoginDetails();
+ account.FirstName = arguments["first"];
+ account.LastName = arguments["last"];
+ account.WebLoginKey = arguments["loginkey"];
+
+ accounts.Add(account);
+ }
else
{
throw new CommandLineArgumentsException();
Index: libsecondlife/examples/TestClient/ClientManager.cs
===================================================================
--- libsecondlife/examples/TestClient/ClientManager.cs (revision 1490)
+++ libsecondlife/examples/TestClient/ClientManager.cs (working copy)
@@ -13,6 +13,7 @@
public string FirstName;
public string LastName;
public string Password;
+ public string WebLoginKey;
public string StartLocation;
public string MasterName;
public LLUUID MasterKey;
@@ -100,6 +101,7 @@
NetworkManager.LoginParams loginParams = client.Network.DefaultLoginParams(
account.FirstName, account.LastName, account.Password, "TestClient", contactPerson);
+ loginParams.WebLoginKey = account.WebLoginKey;
if (!String.IsNullOrEmpty(account.StartLocation))
loginParams.Start = account.StartLocation;