aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MySQL/MySQLManager.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/MySQL/MySQLManager.cs29
1 files changed, 16 insertions, 13 deletions
diff --git a/OpenSim/Data/MySQL/MySQLManager.cs b/OpenSim/Data/MySQL/MySQLManager.cs
index 5f830bb..7096efa 100644
--- a/OpenSim/Data/MySQL/MySQLManager.cs
+++ b/OpenSim/Data/MySQL/MySQLManager.cs
@@ -540,6 +540,7 @@ namespace OpenSim.Data.MySQL
540 retval.ID = id; 540 retval.ID = id;
541 retval.FirstName = (string) reader["username"]; 541 retval.FirstName = (string) reader["username"];
542 retval.SurName = (string) reader["lastname"]; 542 retval.SurName = (string) reader["lastname"];
543 retval.Email = (string) reader["email"];
543 544
544 retval.PasswordHash = (string) reader["passwordHash"]; 545 retval.PasswordHash = (string) reader["passwordHash"];
545 retval.PasswordSalt = (string) reader["passwordSalt"]; 546 retval.PasswordSalt = (string) reader["passwordSalt"];
@@ -768,7 +769,7 @@ namespace OpenSim.Data.MySQL
768 /// <param name="firstImage">UUID for firstlife image</param> 769 /// <param name="firstImage">UUID for firstlife image</param>
769 /// <param name="webLoginKey">Ignored</param> 770 /// <param name="webLoginKey">Ignored</param>
770 /// <returns>Success?</returns> 771 /// <returns>Success?</returns>
771 public bool insertUserRow(UUID uuid, string username, string lastname, string passwordHash, 772 public bool insertUserRow(UUID uuid, string username, string lastname, string email, string passwordHash,
772 string passwordSalt, UInt64 homeRegion, float homeLocX, float homeLocY, float homeLocZ, 773 string passwordSalt, UInt64 homeRegion, float homeLocX, float homeLocY, float homeLocZ,
773 float homeLookAtX, float homeLookAtY, float homeLookAtZ, int created, int lastlogin, 774 float homeLookAtX, float homeLookAtY, float homeLookAtZ, int created, int lastlogin,
774 string inventoryURI, string assetURI, uint canDoMask, uint wantDoMask, 775 string inventoryURI, string assetURI, uint canDoMask, uint wantDoMask,
@@ -777,14 +778,14 @@ namespace OpenSim.Data.MySQL
777 { 778 {
778 m_log.Debug("[MySQLManager]: Fetching profile for " + uuid.ToString()); 779 m_log.Debug("[MySQLManager]: Fetching profile for " + uuid.ToString());
779 string sql = 780 string sql =
780 "INSERT INTO users (`UUID`, `username`, `lastname`, `passwordHash`, `passwordSalt`, `homeRegion`, "; 781 "INSERT INTO users (`UUID`, `username`, `lastname`, `email`, `passwordHash`, `passwordSalt`, `homeRegion`, ";
781 sql += 782 sql +=
782 "`homeLocationX`, `homeLocationY`, `homeLocationZ`, `homeLookAtX`, `homeLookAtY`, `homeLookAtZ`, `created`, "; 783 "`homeLocationX`, `homeLocationY`, `homeLocationZ`, `homeLookAtX`, `homeLookAtY`, `homeLookAtZ`, `created`, ";
783 sql += 784 sql +=
784 "`lastLogin`, `userInventoryURI`, `userAssetURI`, `profileCanDoMask`, `profileWantDoMask`, `profileAboutText`, "; 785 "`lastLogin`, `userInventoryURI`, `userAssetURI`, `profileCanDoMask`, `profileWantDoMask`, `profileAboutText`, ";
785 sql += "`profileFirstText`, `profileImage`, `profileFirstImage`, `webLoginKey`, `userFlags`, `godLevel`, `customType`, `partner`) VALUES "; 786 sql += "`profileFirstText`, `profileImage`, `profileFirstImage`, `webLoginKey`, `userFlags`, `godLevel`, `customType`, `partner`) VALUES ";
786 787
787 sql += "(?UUID, ?username, ?lastname, ?passwordHash, ?passwordSalt, ?homeRegion, "; 788 sql += "(?UUID, ?username, ?lastname, ?email, ?passwordHash, ?passwordSalt, ?homeRegion, ";
788 sql += 789 sql +=
789 "?homeLocationX, ?homeLocationY, ?homeLocationZ, ?homeLookAtX, ?homeLookAtY, ?homeLookAtZ, ?created, "; 790 "?homeLocationX, ?homeLocationY, ?homeLocationZ, ?homeLookAtX, ?homeLookAtY, ?homeLookAtZ, ?created, ";
790 sql += 791 sql +=
@@ -793,10 +794,11 @@ namespace OpenSim.Data.MySQL
793 794
794 Dictionary<string, string> parameters = new Dictionary<string, string>(); 795 Dictionary<string, string> parameters = new Dictionary<string, string>();
795 parameters["?UUID"] = uuid.ToString(); 796 parameters["?UUID"] = uuid.ToString();
796 parameters["?username"] = username.ToString(); 797 parameters["?username"] = username;
797 parameters["?lastname"] = lastname.ToString(); 798 parameters["?lastname"] = lastname;
798 parameters["?passwordHash"] = passwordHash.ToString(); 799 parameters["?email"] = email;
799 parameters["?passwordSalt"] = passwordSalt.ToString(); 800 parameters["?passwordHash"] = passwordHash;
801 parameters["?passwordSalt"] = passwordSalt;
800 parameters["?homeRegion"] = homeRegion.ToString(); 802 parameters["?homeRegion"] = homeRegion.ToString();
801 parameters["?homeLocationX"] = homeLocX.ToString(); 803 parameters["?homeLocationX"] = homeLocX.ToString();
802 parameters["?homeLocationY"] = homeLocY.ToString(); 804 parameters["?homeLocationY"] = homeLocY.ToString();
@@ -869,14 +871,14 @@ namespace OpenSim.Data.MySQL
869 /// <param name="firstImage">UUID for firstlife image</param> 871 /// <param name="firstImage">UUID for firstlife image</param>
870 /// <param name="webLoginKey">UUID for weblogin Key</param> 872 /// <param name="webLoginKey">UUID for weblogin Key</param>
871 /// <returns>Success?</returns> 873 /// <returns>Success?</returns>
872 public bool updateUserRow(UUID uuid, string username, string lastname, string passwordHash, 874 public bool updateUserRow(UUID uuid, string username, string lastname, string email, string passwordHash,
873 string passwordSalt, UInt64 homeRegion, UUID homeRegionID, float homeLocX, float homeLocY, float homeLocZ, 875 string passwordSalt, UInt64 homeRegion, UUID homeRegionID, float homeLocX, float homeLocY, float homeLocZ,
874 float homeLookAtX, float homeLookAtY, float homeLookAtZ, int created, int lastlogin, 876 float homeLookAtX, float homeLookAtY, float homeLookAtZ, int created, int lastlogin,
875 string inventoryURI, string assetURI, uint canDoMask, uint wantDoMask, 877 string inventoryURI, string assetURI, uint canDoMask, uint wantDoMask,
876 string aboutText, string firstText, 878 string aboutText, string firstText,
877 UUID profileImage, UUID firstImage, UUID webLoginKey, int userFlags, int godLevel, string customType, UUID partner) 879 UUID profileImage, UUID firstImage, UUID webLoginKey, int userFlags, int godLevel, string customType, UUID partner)
878 { 880 {
879 string sql = "UPDATE users SET `username` = ?username , `lastname` = ?lastname "; 881 string sql = "UPDATE users SET `username` = ?username , `lastname` = ?lastname, `email` = ?email ";
880 sql += ", `passwordHash` = ?passwordHash , `passwordSalt` = ?passwordSalt , "; 882 sql += ", `passwordHash` = ?passwordHash , `passwordSalt` = ?passwordSalt , ";
881 sql += "`homeRegion` = ?homeRegion , `homeRegionID` = ?homeRegionID, `homeLocationX` = ?homeLocationX , "; 883 sql += "`homeRegion` = ?homeRegion , `homeRegionID` = ?homeRegionID, `homeLocationX` = ?homeLocationX , ";
882 sql += "`homeLocationY` = ?homeLocationY , `homeLocationZ` = ?homeLocationZ , "; 884 sql += "`homeLocationY` = ?homeLocationY , `homeLocationZ` = ?homeLocationZ , ";
@@ -892,10 +894,11 @@ namespace OpenSim.Data.MySQL
892 894
893 Dictionary<string, string> parameters = new Dictionary<string, string>(); 895 Dictionary<string, string> parameters = new Dictionary<string, string>();
894 parameters["?UUID"] = uuid.ToString(); 896 parameters["?UUID"] = uuid.ToString();
895 parameters["?username"] = username.ToString(); 897 parameters["?username"] = username;
896 parameters["?lastname"] = lastname.ToString(); 898 parameters["?lastname"] = lastname;
897 parameters["?passwordHash"] = passwordHash.ToString(); 899 parameters["?email"] = email;
898 parameters["?passwordSalt"] = passwordSalt.ToString(); 900 parameters["?passwordHash"] = passwordHash;
901 parameters["?passwordSalt"] = passwordSalt;
899 parameters["?homeRegion"] = homeRegion.ToString(); 902 parameters["?homeRegion"] = homeRegion.ToString();
900 parameters["?homeRegionID"] = homeRegionID.ToString(); 903 parameters["?homeRegionID"] = homeRegionID.ToString();
901 parameters["?homeLocationX"] = homeLocX.ToString(); 904 parameters["?homeLocationX"] = homeLocX.ToString();