diff options
author | lbsa71 | 2007-07-03 14:37:29 +0000 |
---|---|---|
committer | lbsa71 | 2007-07-03 14:37:29 +0000 |
commit | 9b6b6d05d45cf0f754a0b26bf6240ef50be66563 (patch) | |
tree | 8d72120aac2184c5ed4c5ab5f6b673ef496a0803 /OpenSim/Framework/Data | |
parent | * Completed conceptual LlsdMethod - everything resides in SimpleApp pending g... (diff) | |
download | opensim-SC_OLD-9b6b6d05d45cf0f754a0b26bf6240ef50be66563.zip opensim-SC_OLD-9b6b6d05d45cf0f754a0b26bf6240ef50be66563.tar.gz opensim-SC_OLD-9b6b6d05d45cf0f754a0b26bf6240ef50be66563.tar.bz2 opensim-SC_OLD-9b6b6d05d45cf0f754a0b26bf6240ef50be66563.tar.xz |
* Optimized usings (the 'LL ate my scripts' commit)
* added some licensing info
Diffstat (limited to '')
25 files changed, 90 insertions, 142 deletions
diff --git a/OpenSim/Framework/Data.DB4o/DB4oGridData.cs b/OpenSim/Framework/Data.DB4o/DB4oGridData.cs index dc8488e..1aaa775 100644 --- a/OpenSim/Framework/Data.DB4o/DB4oGridData.cs +++ b/OpenSim/Framework/Data.DB4o/DB4oGridData.cs | |||
@@ -27,12 +27,8 @@ | |||
27 | */ | 27 | */ |
28 | 28 | ||
29 | using System; | 29 | using System; |
30 | using System.Collections.Generic; | ||
31 | using System.Text; | ||
32 | using OpenSim.Framework.Data; | ||
33 | using libsecondlife; | 30 | using libsecondlife; |
34 | 31 | ||
35 | |||
36 | namespace OpenSim.Framework.Data.DB4o | 32 | namespace OpenSim.Framework.Data.DB4o |
37 | { | 33 | { |
38 | /// <summary> | 34 | /// <summary> |
diff --git a/OpenSim/Framework/Data.DB4o/DB4oManager.cs b/OpenSim/Framework/Data.DB4o/DB4oManager.cs index bd4cea8..0df6350 100644 --- a/OpenSim/Framework/Data.DB4o/DB4oManager.cs +++ b/OpenSim/Framework/Data.DB4o/DB4oManager.cs | |||
@@ -27,9 +27,7 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Text; | ||
31 | using Db4objects.Db4o; | 30 | using Db4objects.Db4o; |
32 | using OpenSim.Framework.Data; | ||
33 | using libsecondlife; | 31 | using libsecondlife; |
34 | 32 | ||
35 | namespace OpenSim.Framework.Data.DB4o | 33 | namespace OpenSim.Framework.Data.DB4o |
diff --git a/OpenSim/Framework/Data.DB4o/DB4oUserData.cs b/OpenSim/Framework/Data.DB4o/DB4oUserData.cs index 3ab0073..2e33ab0 100644 --- a/OpenSim/Framework/Data.DB4o/DB4oUserData.cs +++ b/OpenSim/Framework/Data.DB4o/DB4oUserData.cs | |||
@@ -26,9 +26,6 @@ | |||
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | using OpenSim.Framework.Data; | ||
32 | using libsecondlife; | 29 | using libsecondlife; |
33 | 30 | ||
34 | namespace OpenSim.Framework.Data.DB4o | 31 | namespace OpenSim.Framework.Data.DB4o |
diff --git a/OpenSim/Framework/Data.DB4o/Properties/AssemblyInfo.cs b/OpenSim/Framework/Data.DB4o/Properties/AssemblyInfo.cs index 68395a1..905cd9b 100644 --- a/OpenSim/Framework/Data.DB4o/Properties/AssemblyInfo.cs +++ b/OpenSim/Framework/Data.DB4o/Properties/AssemblyInfo.cs | |||
@@ -1,7 +1,5 @@ | |||
1 | using System.Reflection; | 1 | using System.Reflection; |
2 | using System.Runtime.CompilerServices; | ||
3 | using System.Runtime.InteropServices; | 2 | using System.Runtime.InteropServices; |
4 | |||
5 | // General Information about an assembly is controlled through the following | 3 | // General Information about an assembly is controlled through the following |
6 | // set of attributes. Change these attribute values to modify the information | 4 | // set of attributes. Change these attribute values to modify the information |
7 | // associated with an assembly. | 5 | // associated with an assembly. |
diff --git a/OpenSim/Framework/Data.MSSQL/MSSQLGridData.cs b/OpenSim/Framework/Data.MSSQL/MSSQLGridData.cs index 5bdceaf..ca9196a5 100644 --- a/OpenSim/Framework/Data.MSSQL/MSSQLGridData.cs +++ b/OpenSim/Framework/Data.MSSQL/MSSQLGridData.cs | |||
@@ -27,8 +27,10 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Data; | ||
31 | using System.Security.Cryptography; | ||
30 | using System.Text; | 32 | using System.Text; |
31 | using OpenSim.Framework.Data; | 33 | using libsecondlife; |
32 | 34 | ||
33 | namespace OpenSim.Framework.Data.MSSQL | 35 | namespace OpenSim.Framework.Data.MSSQL |
34 | { | 36 | { |
@@ -99,8 +101,8 @@ namespace OpenSim.Framework.Data.MSSQL | |||
99 | Dictionary<string, string> param = new Dictionary<string, string>(); | 101 | Dictionary<string, string> param = new Dictionary<string, string>(); |
100 | param["handle"] = handle.ToString(); | 102 | param["handle"] = handle.ToString(); |
101 | 103 | ||
102 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE handle = @handle", param); | 104 | IDbCommand result = database.Query("SELECT * FROM regions WHERE handle = @handle", param); |
103 | System.Data.IDataReader reader = result.ExecuteReader(); | 105 | IDataReader reader = result.ExecuteReader(); |
104 | 106 | ||
105 | SimProfileData row = database.getRow(reader); | 107 | SimProfileData row = database.getRow(reader); |
106 | reader.Close(); | 108 | reader.Close(); |
@@ -114,13 +116,13 @@ namespace OpenSim.Framework.Data.MSSQL | |||
114 | /// </summary> | 116 | /// </summary> |
115 | /// <param name="uuid">The region UUID</param> | 117 | /// <param name="uuid">The region UUID</param> |
116 | /// <returns>The sim profile</returns> | 118 | /// <returns>The sim profile</returns> |
117 | public SimProfileData GetProfileByLLUUID(libsecondlife.LLUUID uuid) | 119 | public SimProfileData GetProfileByLLUUID(LLUUID uuid) |
118 | { | 120 | { |
119 | Dictionary<string, string> param = new Dictionary<string, string>(); | 121 | Dictionary<string, string> param = new Dictionary<string, string>(); |
120 | param["uuid"] = uuid.ToStringHyphenated(); | 122 | param["uuid"] = uuid.ToStringHyphenated(); |
121 | 123 | ||
122 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = @uuid", param); | 124 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = @uuid", param); |
123 | System.Data.IDataReader reader = result.ExecuteReader(); | 125 | IDataReader reader = result.ExecuteReader(); |
124 | 126 | ||
125 | SimProfileData row = database.getRow(reader); | 127 | SimProfileData row = database.getRow(reader); |
126 | reader.Close(); | 128 | reader.Close(); |
@@ -153,7 +155,7 @@ namespace OpenSim.Framework.Data.MSSQL | |||
153 | /// <param name="handle">The attempted regionHandle of the challenger</param> | 155 | /// <param name="handle">The attempted regionHandle of the challenger</param> |
154 | /// <param name="authkey">The secret</param> | 156 | /// <param name="authkey">The secret</param> |
155 | /// <returns>Whether the secret and regionhandle match the database entry for UUID</returns> | 157 | /// <returns>Whether the secret and regionhandle match the database entry for UUID</returns> |
156 | public bool AuthenticateSim(libsecondlife.LLUUID uuid, ulong handle, string authkey) | 158 | public bool AuthenticateSim(LLUUID uuid, ulong handle, string authkey) |
157 | { | 159 | { |
158 | bool throwHissyFit = false; // Should be true by 1.0 | 160 | bool throwHissyFit = false; // Should be true by 1.0 |
159 | 161 | ||
@@ -174,10 +176,10 @@ namespace OpenSim.Framework.Data.MSSQL | |||
174 | /// <param name="authhash"></param> | 176 | /// <param name="authhash"></param> |
175 | /// <param name="challenge"></param> | 177 | /// <param name="challenge"></param> |
176 | /// <returns></returns> | 178 | /// <returns></returns> |
177 | public bool AuthenticateSim(libsecondlife.LLUUID uuid, ulong handle, string authhash, string challenge) | 179 | public bool AuthenticateSim(LLUUID uuid, ulong handle, string authhash, string challenge) |
178 | { | 180 | { |
179 | System.Security.Cryptography.SHA512Managed HashProvider = new System.Security.Cryptography.SHA512Managed(); | 181 | SHA512Managed HashProvider = new SHA512Managed(); |
180 | System.Text.ASCIIEncoding TextProvider = new ASCIIEncoding(); | 182 | ASCIIEncoding TextProvider = new ASCIIEncoding(); |
181 | 183 | ||
182 | byte[] stream = TextProvider.GetBytes(uuid.ToStringHyphenated() + ":" + handle.ToString() + ":" + challenge); | 184 | byte[] stream = TextProvider.GetBytes(uuid.ToStringHyphenated() + ":" + handle.ToString() + ":" + challenge); |
183 | byte[] hash = HashProvider.ComputeHash(stream); | 185 | byte[] hash = HashProvider.ComputeHash(stream); |
diff --git a/OpenSim/Framework/Data.MSSQL/MSSQLManager.cs b/OpenSim/Framework/Data.MSSQL/MSSQLManager.cs index 3c83c1f..49bf31c 100644 --- a/OpenSim/Framework/Data.MSSQL/MSSQLManager.cs +++ b/OpenSim/Framework/Data.MSSQL/MSSQLManager.cs | |||
@@ -27,12 +27,9 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Text; | ||
31 | using System.Data; | 30 | using System.Data; |
32 | |||
33 | using System.Data.SqlClient; | 31 | using System.Data.SqlClient; |
34 | 32 | using libsecondlife; | |
35 | using OpenSim.Framework.Data; | ||
36 | 33 | ||
37 | namespace OpenSim.Framework.Data.MSSQL | 34 | namespace OpenSim.Framework.Data.MSSQL |
38 | { | 35 | { |
@@ -110,7 +107,7 @@ namespace OpenSim.Framework.Data.MSSQL | |||
110 | // Region Main | 107 | // Region Main |
111 | regionprofile.regionHandle = (ulong)reader["regionHandle"]; | 108 | regionprofile.regionHandle = (ulong)reader["regionHandle"]; |
112 | regionprofile.regionName = (string)reader["regionName"]; | 109 | regionprofile.regionName = (string)reader["regionName"]; |
113 | regionprofile.UUID = new libsecondlife.LLUUID((string)reader["uuid"]); | 110 | regionprofile.UUID = new LLUUID((string)reader["uuid"]); |
114 | 111 | ||
115 | // Secrets | 112 | // Secrets |
116 | regionprofile.regionRecvKey = (string)reader["regionRecvKey"]; | 113 | regionprofile.regionRecvKey = (string)reader["regionRecvKey"]; |
diff --git a/OpenSim/Framework/Data.MSSQL/Properties/AssemblyInfo.cs b/OpenSim/Framework/Data.MSSQL/Properties/AssemblyInfo.cs index af310e8..066c739 100644 --- a/OpenSim/Framework/Data.MSSQL/Properties/AssemblyInfo.cs +++ b/OpenSim/Framework/Data.MSSQL/Properties/AssemblyInfo.cs | |||
@@ -1,7 +1,5 @@ | |||
1 | using System.Reflection; | 1 | using System.Reflection; |
2 | using System.Runtime.CompilerServices; | ||
3 | using System.Runtime.InteropServices; | 2 | using System.Runtime.InteropServices; |
4 | |||
5 | // General Information about an assembly is controlled through the following | 3 | // General Information about an assembly is controlled through the following |
6 | // set of attributes. Change these attribute values to modify the information | 4 | // set of attributes. Change these attribute values to modify the information |
7 | // associated with an assembly. | 5 | // associated with an assembly. |
diff --git a/OpenSim/Framework/Data.MySQL/MySQLGridData.cs b/OpenSim/Framework/Data.MySQL/MySQLGridData.cs index 43e3054..ef643d2 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLGridData.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLGridData.cs | |||
@@ -27,8 +27,10 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Data; | ||
31 | using System.Security.Cryptography; | ||
30 | using System.Text; | 32 | using System.Text; |
31 | using OpenSim.Framework.Data; | 33 | using libsecondlife; |
32 | 34 | ||
33 | namespace OpenSim.Framework.Data.MySQL | 35 | namespace OpenSim.Framework.Data.MySQL |
34 | { | 36 | { |
@@ -104,8 +106,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
104 | param["?xmax"] = xmax.ToString(); | 106 | param["?xmax"] = xmax.ToString(); |
105 | param["?ymax"] = ymax.ToString(); | 107 | param["?ymax"] = ymax.ToString(); |
106 | 108 | ||
107 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE locX >= ?xmin AND locX <= ?xmax AND locY >= ?ymin AND locY <= ?ymax", param); | 109 | IDbCommand result = database.Query("SELECT * FROM regions WHERE locX >= ?xmin AND locX <= ?xmax AND locY >= ?ymin AND locY <= ?ymax", param); |
108 | System.Data.IDataReader reader = result.ExecuteReader(); | 110 | IDataReader reader = result.ExecuteReader(); |
109 | 111 | ||
110 | SimProfileData row; | 112 | SimProfileData row; |
111 | 113 | ||
@@ -144,8 +146,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
144 | Dictionary<string, string> param = new Dictionary<string, string>(); | 146 | Dictionary<string, string> param = new Dictionary<string, string>(); |
145 | param["?handle"] = handle.ToString(); | 147 | param["?handle"] = handle.ToString(); |
146 | 148 | ||
147 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE regionHandle = ?handle", param); | 149 | IDbCommand result = database.Query("SELECT * FROM regions WHERE regionHandle = ?handle", param); |
148 | System.Data.IDataReader reader = result.ExecuteReader(); | 150 | IDataReader reader = result.ExecuteReader(); |
149 | 151 | ||
150 | SimProfileData row = database.readSimRow(reader); | 152 | SimProfileData row = database.readSimRow(reader); |
151 | reader.Close(); | 153 | reader.Close(); |
@@ -167,7 +169,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
167 | /// </summary> | 169 | /// </summary> |
168 | /// <param name="uuid">The region UUID</param> | 170 | /// <param name="uuid">The region UUID</param> |
169 | /// <returns>The sim profile</returns> | 171 | /// <returns>The sim profile</returns> |
170 | public SimProfileData GetProfileByLLUUID(libsecondlife.LLUUID uuid) | 172 | public SimProfileData GetProfileByLLUUID(LLUUID uuid) |
171 | { | 173 | { |
172 | try | 174 | try |
173 | { | 175 | { |
@@ -176,8 +178,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
176 | Dictionary<string, string> param = new Dictionary<string, string>(); | 178 | Dictionary<string, string> param = new Dictionary<string, string>(); |
177 | param["?uuid"] = uuid.ToStringHyphenated(); | 179 | param["?uuid"] = uuid.ToStringHyphenated(); |
178 | 180 | ||
179 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = ?uuid", param); | 181 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = ?uuid", param); |
180 | System.Data.IDataReader reader = result.ExecuteReader(); | 182 | IDataReader reader = result.ExecuteReader(); |
181 | 183 | ||
182 | SimProfileData row = database.readSimRow(reader); | 184 | SimProfileData row = database.readSimRow(reader); |
183 | reader.Close(); | 185 | reader.Close(); |
@@ -221,7 +223,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
221 | /// <param name="handle">The attempted regionHandle of the challenger</param> | 223 | /// <param name="handle">The attempted regionHandle of the challenger</param> |
222 | /// <param name="authkey">The secret</param> | 224 | /// <param name="authkey">The secret</param> |
223 | /// <returns>Whether the secret and regionhandle match the database entry for UUID</returns> | 225 | /// <returns>Whether the secret and regionhandle match the database entry for UUID</returns> |
224 | public bool AuthenticateSim(libsecondlife.LLUUID uuid, ulong handle, string authkey) | 226 | public bool AuthenticateSim(LLUUID uuid, ulong handle, string authkey) |
225 | { | 227 | { |
226 | bool throwHissyFit = false; // Should be true by 1.0 | 228 | bool throwHissyFit = false; // Should be true by 1.0 |
227 | 229 | ||
@@ -242,10 +244,10 @@ namespace OpenSim.Framework.Data.MySQL | |||
242 | /// <param name="authhash"></param> | 244 | /// <param name="authhash"></param> |
243 | /// <param name="challenge"></param> | 245 | /// <param name="challenge"></param> |
244 | /// <returns></returns> | 246 | /// <returns></returns> |
245 | public bool AuthenticateSim(libsecondlife.LLUUID uuid, ulong handle, string authhash, string challenge) | 247 | public bool AuthenticateSim(LLUUID uuid, ulong handle, string authhash, string challenge) |
246 | { | 248 | { |
247 | System.Security.Cryptography.SHA512Managed HashProvider = new System.Security.Cryptography.SHA512Managed(); | 249 | SHA512Managed HashProvider = new SHA512Managed(); |
248 | System.Text.ASCIIEncoding TextProvider = new ASCIIEncoding(); | 250 | ASCIIEncoding TextProvider = new ASCIIEncoding(); |
249 | 251 | ||
250 | byte[] stream = TextProvider.GetBytes(uuid.ToStringHyphenated() + ":" + handle.ToString() + ":" + challenge); | 252 | byte[] stream = TextProvider.GetBytes(uuid.ToStringHyphenated() + ":" + handle.ToString() + ":" + challenge); |
251 | byte[] hash = HashProvider.ComputeHash(stream); | 253 | byte[] hash = HashProvider.ComputeHash(stream); |
@@ -262,8 +264,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
262 | Dictionary<string, string> param = new Dictionary<string, string>(); | 264 | Dictionary<string, string> param = new Dictionary<string, string>(); |
263 | param["?x"] = x.ToString(); | 265 | param["?x"] = x.ToString(); |
264 | param["?y"] = y.ToString(); | 266 | param["?y"] = y.ToString(); |
265 | System.Data.IDbCommand result = database.Query("SELECT * FROM reservations WHERE resXMin <= ?x AND resXMax >= ?x AND resYMin <= ?y AND resYMax >= ?y", param); | 267 | IDbCommand result = database.Query("SELECT * FROM reservations WHERE resXMin <= ?x AND resXMax >= ?x AND resYMin <= ?y AND resYMax >= ?y", param); |
266 | System.Data.IDataReader reader = result.ExecuteReader(); | 268 | IDataReader reader = result.ExecuteReader(); |
267 | 269 | ||
268 | ReservationData row = database.readReservationRow(reader); | 270 | ReservationData row = database.readReservationRow(reader); |
269 | reader.Close(); | 271 | reader.Close(); |
diff --git a/OpenSim/Framework/Data.MySQL/MySQLInventoryData.cs b/OpenSim/Framework/Data.MySQL/MySQLInventoryData.cs index 434df1a..790759a 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLInventoryData.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLInventoryData.cs | |||
@@ -27,7 +27,7 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Text; | 30 | using System.Data; |
31 | using libsecondlife; | 31 | using libsecondlife; |
32 | 32 | ||
33 | namespace OpenSim.Framework.Data.MySQL | 33 | namespace OpenSim.Framework.Data.MySQL |
@@ -98,8 +98,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
98 | Dictionary<string, string> param = new Dictionary<string, string>(); | 98 | Dictionary<string, string> param = new Dictionary<string, string>(); |
99 | param["?uuid"] = folderID.ToStringHyphenated(); | 99 | param["?uuid"] = folderID.ToStringHyphenated(); |
100 | 100 | ||
101 | System.Data.IDbCommand result = database.Query("SELECT * FROM inventoryitems WHERE parentFolderID = ?uuid", param); | 101 | IDbCommand result = database.Query("SELECT * FROM inventoryitems WHERE parentFolderID = ?uuid", param); |
102 | System.Data.IDataReader reader = result.ExecuteReader(); | 102 | IDataReader reader = result.ExecuteReader(); |
103 | 103 | ||
104 | List<InventoryItemBase> items = database.readInventoryItems(reader); | 104 | List<InventoryItemBase> items = database.readInventoryItems(reader); |
105 | 105 | ||
@@ -132,8 +132,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
132 | param["?uuid"] = user.ToStringHyphenated(); | 132 | param["?uuid"] = user.ToStringHyphenated(); |
133 | param["?zero"] = LLUUID.Zero.ToStringHyphenated(); | 133 | param["?zero"] = LLUUID.Zero.ToStringHyphenated(); |
134 | 134 | ||
135 | System.Data.IDbCommand result = database.Query("SELECT * FROM inventoryfolders WHERE parentFolderID = ?zero AND agentID = ?uuid", param); | 135 | IDbCommand result = database.Query("SELECT * FROM inventoryfolders WHERE parentFolderID = ?zero AND agentID = ?uuid", param); |
136 | System.Data.IDataReader reader = result.ExecuteReader(); | 136 | IDataReader reader = result.ExecuteReader(); |
137 | 137 | ||
138 | List<InventoryFolderBase> items = database.readInventoryFolders(reader); | 138 | List<InventoryFolderBase> items = database.readInventoryFolders(reader); |
139 | 139 | ||
@@ -165,8 +165,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
165 | Dictionary<string, string> param = new Dictionary<string, string>(); | 165 | Dictionary<string, string> param = new Dictionary<string, string>(); |
166 | param["?uuid"] = parentID.ToStringHyphenated(); | 166 | param["?uuid"] = parentID.ToStringHyphenated(); |
167 | 167 | ||
168 | System.Data.IDbCommand result = database.Query("SELECT * FROM inventoryfolders WHERE parentFolderID = ?uuid", param); | 168 | IDbCommand result = database.Query("SELECT * FROM inventoryfolders WHERE parentFolderID = ?uuid", param); |
169 | System.Data.IDataReader reader = result.ExecuteReader(); | 169 | IDataReader reader = result.ExecuteReader(); |
170 | 170 | ||
171 | List<InventoryFolderBase> items = database.readInventoryFolders(reader); | 171 | List<InventoryFolderBase> items = database.readInventoryFolders(reader); |
172 | 172 | ||
@@ -198,8 +198,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
198 | Dictionary<string, string> param = new Dictionary<string, string>(); | 198 | Dictionary<string, string> param = new Dictionary<string, string>(); |
199 | param["?uuid"] = item.ToStringHyphenated(); | 199 | param["?uuid"] = item.ToStringHyphenated(); |
200 | 200 | ||
201 | System.Data.IDbCommand result = database.Query("SELECT * FROM inventoryitems WHERE inventoryID = ?uuid", param); | 201 | IDbCommand result = database.Query("SELECT * FROM inventoryitems WHERE inventoryID = ?uuid", param); |
202 | System.Data.IDataReader reader = result.ExecuteReader(); | 202 | IDataReader reader = result.ExecuteReader(); |
203 | 203 | ||
204 | List<InventoryItemBase> items = database.readInventoryItems(reader); | 204 | List<InventoryItemBase> items = database.readInventoryItems(reader); |
205 | 205 | ||
@@ -238,8 +238,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
238 | Dictionary<string, string> param = new Dictionary<string, string>(); | 238 | Dictionary<string, string> param = new Dictionary<string, string>(); |
239 | param["?uuid"] = folder.ToStringHyphenated(); | 239 | param["?uuid"] = folder.ToStringHyphenated(); |
240 | 240 | ||
241 | System.Data.IDbCommand result = database.Query("SELECT * FROM inventoryfolders WHERE folderID = ?uuid", param); | 241 | IDbCommand result = database.Query("SELECT * FROM inventoryfolders WHERE folderID = ?uuid", param); |
242 | System.Data.IDataReader reader = result.ExecuteReader(); | 242 | IDataReader reader = result.ExecuteReader(); |
243 | 243 | ||
244 | List<InventoryFolderBase> items = database.readInventoryFolders(reader); | 244 | List<InventoryFolderBase> items = database.readInventoryFolders(reader); |
245 | 245 | ||
diff --git a/OpenSim/Framework/Data.MySQL/MySQLLogData.cs b/OpenSim/Framework/Data.MySQL/MySQLLogData.cs index 8265614..66f3399 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLLogData.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLLogData.cs | |||
@@ -26,8 +26,6 @@ | |||
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | 29 | ||
32 | namespace OpenSim.Framework.Data.MySQL | 30 | namespace OpenSim.Framework.Data.MySQL |
33 | { | 31 | { |
diff --git a/OpenSim/Framework/Data.MySQL/MySQLManager.cs b/OpenSim/Framework/Data.MySQL/MySQLManager.cs index b2f398b..ab478ed 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLManager.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLManager.cs | |||
@@ -27,17 +27,10 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Text; | ||
31 | using System.Data; | 30 | using System.Data; |
32 | 31 | using libsecondlife; | |
33 | // MySQL Native | ||
34 | using MySql; | ||
35 | using MySql.Data; | ||
36 | using MySql.Data.Types; | ||
37 | using MySql.Data.MySqlClient; | 32 | using MySql.Data.MySqlClient; |
38 | 33 | ||
39 | using OpenSim.Framework.Data; | ||
40 | |||
41 | namespace OpenSim.Framework.Data.MySQL | 34 | namespace OpenSim.Framework.Data.MySQL |
42 | { | 35 | { |
43 | /// <summary> | 36 | /// <summary> |
@@ -71,7 +64,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
71 | 64 | ||
72 | dbcon.Open(); | 65 | dbcon.Open(); |
73 | 66 | ||
74 | System.Console.WriteLine("MySQL connection established"); | 67 | Console.WriteLine("MySQL connection established"); |
75 | } | 68 | } |
76 | catch (Exception e) | 69 | catch (Exception e) |
77 | { | 70 | { |
@@ -187,7 +180,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
187 | // Region Main | 180 | // Region Main |
188 | retval.regionHandle = Convert.ToUInt64(reader["regionHandle"].ToString()); | 181 | retval.regionHandle = Convert.ToUInt64(reader["regionHandle"].ToString()); |
189 | retval.regionName = (string)reader["regionName"]; | 182 | retval.regionName = (string)reader["regionName"]; |
190 | retval.UUID = new libsecondlife.LLUUID((string)reader["uuid"]); | 183 | retval.UUID = new LLUUID((string)reader["uuid"]); |
191 | 184 | ||
192 | // Secrets | 185 | // Secrets |
193 | retval.regionRecvKey = (string)reader["regionRecvKey"]; | 186 | retval.regionRecvKey = (string)reader["regionRecvKey"]; |
@@ -226,11 +219,11 @@ namespace OpenSim.Framework.Data.MySQL | |||
226 | string tempRegionMap = reader["regionMapTexture"].ToString(); | 219 | string tempRegionMap = reader["regionMapTexture"].ToString(); |
227 | if (tempRegionMap != "") | 220 | if (tempRegionMap != "") |
228 | { | 221 | { |
229 | retval.regionMapTextureID = new libsecondlife.LLUUID(tempRegionMap); | 222 | retval.regionMapTextureID = new LLUUID(tempRegionMap); |
230 | } | 223 | } |
231 | else | 224 | else |
232 | { | 225 | { |
233 | retval.regionMapTextureID = new libsecondlife.LLUUID(); | 226 | retval.regionMapTextureID = new LLUUID(); |
234 | } | 227 | } |
235 | } | 228 | } |
236 | else | 229 | else |
@@ -259,7 +252,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
259 | retval.reservationMinY = (int)reader["resYMin"]; | 252 | retval.reservationMinY = (int)reader["resYMin"]; |
260 | retval.reservationName = (string)reader["resName"]; | 253 | retval.reservationName = (string)reader["resName"]; |
261 | retval.status = (bool)reader["status"]; | 254 | retval.status = (bool)reader["status"]; |
262 | retval.userUUID = new libsecondlife.LLUUID((string)reader["userUUID"]); | 255 | retval.userUUID = new LLUUID((string)reader["userUUID"]); |
263 | 256 | ||
264 | } | 257 | } |
265 | else | 258 | else |
@@ -280,9 +273,9 @@ namespace OpenSim.Framework.Data.MySQL | |||
280 | if (reader.Read()) | 273 | if (reader.Read()) |
281 | { | 274 | { |
282 | // Agent IDs | 275 | // Agent IDs |
283 | retval.UUID = new libsecondlife.LLUUID((string)reader["UUID"]); | 276 | retval.UUID = new LLUUID((string)reader["UUID"]); |
284 | retval.sessionID = new libsecondlife.LLUUID((string)reader["sessionID"]); | 277 | retval.sessionID = new LLUUID((string)reader["sessionID"]); |
285 | retval.secureSessionID = new libsecondlife.LLUUID((string)reader["secureSessionID"]); | 278 | retval.secureSessionID = new LLUUID((string)reader["secureSessionID"]); |
286 | 279 | ||
287 | // Agent Who? | 280 | // Agent Who? |
288 | retval.agentIP = (string)reader["agentIP"]; | 281 | retval.agentIP = (string)reader["agentIP"]; |
@@ -296,7 +289,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
296 | // Current position | 289 | // Current position |
297 | retval.currentRegion = (string)reader["currentRegion"]; | 290 | retval.currentRegion = (string)reader["currentRegion"]; |
298 | retval.currentHandle = Convert.ToUInt64(reader["currentHandle"].ToString()); | 291 | retval.currentHandle = Convert.ToUInt64(reader["currentHandle"].ToString()); |
299 | libsecondlife.LLVector3.TryParse((string)reader["currentPos"], out retval.currentPos); | 292 | LLVector3.TryParse((string)reader["currentPos"], out retval.currentPos); |
300 | } | 293 | } |
301 | else | 294 | else |
302 | { | 295 | { |
@@ -316,7 +309,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
316 | 309 | ||
317 | if (reader.Read()) | 310 | if (reader.Read()) |
318 | { | 311 | { |
319 | retval.UUID = new libsecondlife.LLUUID((string)reader["UUID"]); | 312 | retval.UUID = new LLUUID((string)reader["UUID"]); |
320 | retval.username = (string)reader["username"]; | 313 | retval.username = (string)reader["username"]; |
321 | retval.surname = (string)reader["lastname"]; | 314 | retval.surname = (string)reader["lastname"]; |
322 | 315 | ||
@@ -324,11 +317,11 @@ namespace OpenSim.Framework.Data.MySQL | |||
324 | retval.passwordSalt = (string)reader["passwordSalt"]; | 317 | retval.passwordSalt = (string)reader["passwordSalt"]; |
325 | 318 | ||
326 | retval.homeRegion = Convert.ToUInt64(reader["homeRegion"].ToString()); | 319 | retval.homeRegion = Convert.ToUInt64(reader["homeRegion"].ToString()); |
327 | retval.homeLocation = new libsecondlife.LLVector3( | 320 | retval.homeLocation = new LLVector3( |
328 | Convert.ToSingle(reader["homeLocationX"].ToString()), | 321 | Convert.ToSingle(reader["homeLocationX"].ToString()), |
329 | Convert.ToSingle(reader["homeLocationY"].ToString()), | 322 | Convert.ToSingle(reader["homeLocationY"].ToString()), |
330 | Convert.ToSingle(reader["homeLocationZ"].ToString())); | 323 | Convert.ToSingle(reader["homeLocationZ"].ToString())); |
331 | retval.homeLookAt = new libsecondlife.LLVector3( | 324 | retval.homeLookAt = new LLVector3( |
332 | Convert.ToSingle(reader["homeLookAtX"].ToString()), | 325 | Convert.ToSingle(reader["homeLookAtX"].ToString()), |
333 | Convert.ToSingle(reader["homeLookAtY"].ToString()), | 326 | Convert.ToSingle(reader["homeLookAtY"].ToString()), |
334 | Convert.ToSingle(reader["homeLookAtZ"].ToString())); | 327 | Convert.ToSingle(reader["homeLookAtZ"].ToString())); |
@@ -345,8 +338,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
345 | retval.profileAboutText = (string)reader["profileAboutText"]; | 338 | retval.profileAboutText = (string)reader["profileAboutText"]; |
346 | retval.profileFirstText = (string)reader["profileFirstText"]; | 339 | retval.profileFirstText = (string)reader["profileFirstText"]; |
347 | 340 | ||
348 | retval.profileImage = new libsecondlife.LLUUID((string)reader["profileImage"]); | 341 | retval.profileImage = new LLUUID((string)reader["profileImage"]); |
349 | retval.profileFirstImage = new libsecondlife.LLUUID((string)reader["profileFirstImage"]); | 342 | retval.profileFirstImage = new LLUUID((string)reader["profileFirstImage"]); |
350 | 343 | ||
351 | } | 344 | } |
352 | else | 345 | else |
@@ -371,9 +364,9 @@ namespace OpenSim.Framework.Data.MySQL | |||
371 | { | 364 | { |
372 | InventoryFolderBase folder = new InventoryFolderBase(); | 365 | InventoryFolderBase folder = new InventoryFolderBase(); |
373 | 366 | ||
374 | folder.agentID = new libsecondlife.LLUUID((string)reader["agentID"]); | 367 | folder.agentID = new LLUUID((string)reader["agentID"]); |
375 | folder.parentID = new libsecondlife.LLUUID((string)reader["parentFolderID"]); | 368 | folder.parentID = new LLUUID((string)reader["parentFolderID"]); |
376 | folder.folderID = new libsecondlife.LLUUID((string)reader["folderID"]); | 369 | folder.folderID = new LLUUID((string)reader["folderID"]); |
377 | folder.name = (string)reader["folderName"]; | 370 | folder.name = (string)reader["folderName"]; |
378 | 371 | ||
379 | rows.Add(folder); | 372 | rows.Add(folder); |
@@ -402,14 +395,14 @@ namespace OpenSim.Framework.Data.MySQL | |||
402 | { | 395 | { |
403 | InventoryItemBase item = new InventoryItemBase(); | 396 | InventoryItemBase item = new InventoryItemBase(); |
404 | 397 | ||
405 | item.assetID = new libsecondlife.LLUUID((string)reader["assetID"]); | 398 | item.assetID = new LLUUID((string)reader["assetID"]); |
406 | item.avatarID = new libsecondlife.LLUUID((string)reader["avatarID"]); | 399 | item.avatarID = new LLUUID((string)reader["avatarID"]); |
407 | item.inventoryCurrentPermissions = Convert.ToUInt32(reader["inventoryCurrentPermissions"].ToString()); | 400 | item.inventoryCurrentPermissions = Convert.ToUInt32(reader["inventoryCurrentPermissions"].ToString()); |
408 | item.inventoryDescription = (string)reader["inventoryDescription"]; | 401 | item.inventoryDescription = (string)reader["inventoryDescription"]; |
409 | item.inventoryID = new libsecondlife.LLUUID((string)reader["inventoryID"]); | 402 | item.inventoryID = new LLUUID((string)reader["inventoryID"]); |
410 | item.inventoryName = (string)reader["inventoryName"]; | 403 | item.inventoryName = (string)reader["inventoryName"]; |
411 | item.inventoryNextPermissions = Convert.ToUInt32(reader["inventoryNextPermissions"].ToString()); | 404 | item.inventoryNextPermissions = Convert.ToUInt32(reader["inventoryNextPermissions"].ToString()); |
412 | item.parentFolderID = new libsecondlife.LLUUID((string)reader["parentFolderID"]); | 405 | item.parentFolderID = new LLUUID((string)reader["parentFolderID"]); |
413 | item.type = Convert.ToInt32(reader["type"].ToString()); | 406 | item.type = Convert.ToInt32(reader["type"].ToString()); |
414 | 407 | ||
415 | rows.Add(item); | 408 | rows.Add(item); |
diff --git a/OpenSim/Framework/Data.MySQL/MySQLUserData.cs b/OpenSim/Framework/Data.MySQL/MySQLUserData.cs index 0304452..c116536 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLUserData.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLUserData.cs | |||
@@ -27,8 +27,7 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Text; | 30 | using System.Data; |
31 | using OpenSim.Framework.Data; | ||
32 | using libsecondlife; | 31 | using libsecondlife; |
33 | 32 | ||
34 | namespace OpenSim.Framework.Data.MySQL | 33 | namespace OpenSim.Framework.Data.MySQL |
@@ -87,8 +86,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
87 | param["?first"] = user; | 86 | param["?first"] = user; |
88 | param["?second"] = last; | 87 | param["?second"] = last; |
89 | 88 | ||
90 | System.Data.IDbCommand result = database.Query("SELECT * FROM users WHERE username = ?first AND lastname = ?second", param); | 89 | IDbCommand result = database.Query("SELECT * FROM users WHERE username = ?first AND lastname = ?second", param); |
91 | System.Data.IDataReader reader = result.ExecuteReader(); | 90 | IDataReader reader = result.ExecuteReader(); |
92 | 91 | ||
93 | UserProfileData row = database.readUserRow(reader); | 92 | UserProfileData row = database.readUserRow(reader); |
94 | 93 | ||
@@ -120,8 +119,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
120 | Dictionary<string, string> param = new Dictionary<string, string>(); | 119 | Dictionary<string, string> param = new Dictionary<string, string>(); |
121 | param["?uuid"] = uuid.ToStringHyphenated(); | 120 | param["?uuid"] = uuid.ToStringHyphenated(); |
122 | 121 | ||
123 | System.Data.IDbCommand result = database.Query("SELECT * FROM users WHERE UUID = ?uuid", param); | 122 | IDbCommand result = database.Query("SELECT * FROM users WHERE UUID = ?uuid", param); |
124 | System.Data.IDataReader reader = result.ExecuteReader(); | 123 | IDataReader reader = result.ExecuteReader(); |
125 | 124 | ||
126 | UserProfileData row = database.readUserRow(reader); | 125 | UserProfileData row = database.readUserRow(reader); |
127 | 126 | ||
@@ -175,8 +174,8 @@ namespace OpenSim.Framework.Data.MySQL | |||
175 | Dictionary<string, string> param = new Dictionary<string, string>(); | 174 | Dictionary<string, string> param = new Dictionary<string, string>(); |
176 | param["?uuid"] = uuid.ToStringHyphenated(); | 175 | param["?uuid"] = uuid.ToStringHyphenated(); |
177 | 176 | ||
178 | System.Data.IDbCommand result = database.Query("SELECT * FROM agents WHERE UUID = ?uuid", param); | 177 | IDbCommand result = database.Query("SELECT * FROM agents WHERE UUID = ?uuid", param); |
179 | System.Data.IDataReader reader = result.ExecuteReader(); | 178 | IDataReader reader = result.ExecuteReader(); |
180 | 179 | ||
181 | UserAgentData row = database.readAgentRow(reader); | 180 | UserAgentData row = database.readAgentRow(reader); |
182 | 181 | ||
diff --git a/OpenSim/Framework/Data.MySQL/Properties/AssemblyInfo.cs b/OpenSim/Framework/Data.MySQL/Properties/AssemblyInfo.cs index d67ccf6..52d6a54 100644 --- a/OpenSim/Framework/Data.MySQL/Properties/AssemblyInfo.cs +++ b/OpenSim/Framework/Data.MySQL/Properties/AssemblyInfo.cs | |||
@@ -1,7 +1,5 @@ | |||
1 | using System.Reflection; | 1 | using System.Reflection; |
2 | using System.Runtime.CompilerServices; | ||
3 | using System.Runtime.InteropServices; | 2 | using System.Runtime.InteropServices; |
4 | |||
5 | // General Information about an assembly is controlled through the following | 3 | // General Information about an assembly is controlled through the following |
6 | // set of attributes. Change these attribute values to modify the information | 4 | // set of attributes. Change these attribute values to modify the information |
7 | // associated with an assembly. | 5 | // associated with an assembly. |
diff --git a/OpenSim/Framework/Data.SQLite/Properties/AssemblyInfo.cs b/OpenSim/Framework/Data.SQLite/Properties/AssemblyInfo.cs index f811825..9de5edb 100644 --- a/OpenSim/Framework/Data.SQLite/Properties/AssemblyInfo.cs +++ b/OpenSim/Framework/Data.SQLite/Properties/AssemblyInfo.cs | |||
@@ -1,7 +1,5 @@ | |||
1 | using System.Reflection; | 1 | using System.Reflection; |
2 | using System.Runtime.CompilerServices; | ||
3 | using System.Runtime.InteropServices; | 2 | using System.Runtime.InteropServices; |
4 | |||
5 | // General Information about an assembly is controlled through the following | 3 | // General Information about an assembly is controlled through the following |
6 | // set of attributes. Change these attribute values to modify the information | 4 | // set of attributes. Change these attribute values to modify the information |
7 | // associated with an assembly. | 5 | // associated with an assembly. |
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs b/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs index 800e26c..511c5f0 100644 --- a/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs +++ b/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs | |||
@@ -27,8 +27,10 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Data; | ||
31 | using System.Security.Cryptography; | ||
30 | using System.Text; | 32 | using System.Text; |
31 | using OpenSim.Framework.Data; | 33 | using libsecondlife; |
32 | 34 | ||
33 | namespace OpenSim.Framework.Data.SQLite | 35 | namespace OpenSim.Framework.Data.SQLite |
34 | { | 36 | { |
@@ -99,8 +101,8 @@ namespace OpenSim.Framework.Data.SQLite | |||
99 | Dictionary<string, string> param = new Dictionary<string, string>(); | 101 | Dictionary<string, string> param = new Dictionary<string, string>(); |
100 | param["handle"] = handle.ToString(); | 102 | param["handle"] = handle.ToString(); |
101 | 103 | ||
102 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE handle = @handle", param); | 104 | IDbCommand result = database.Query("SELECT * FROM regions WHERE handle = @handle", param); |
103 | System.Data.IDataReader reader = result.ExecuteReader(); | 105 | IDataReader reader = result.ExecuteReader(); |
104 | 106 | ||
105 | SimProfileData row = database.getRow(reader); | 107 | SimProfileData row = database.getRow(reader); |
106 | reader.Close(); | 108 | reader.Close(); |
@@ -114,13 +116,13 @@ namespace OpenSim.Framework.Data.SQLite | |||
114 | /// </summary> | 116 | /// </summary> |
115 | /// <param name="uuid">The region UUID</param> | 117 | /// <param name="uuid">The region UUID</param> |
116 | /// <returns>The sim profile</returns> | 118 | /// <returns>The sim profile</returns> |
117 | public SimProfileData GetProfileByLLUUID(libsecondlife.LLUUID uuid) | 119 | public SimProfileData GetProfileByLLUUID(LLUUID uuid) |
118 | { | 120 | { |
119 | Dictionary<string, string> param = new Dictionary<string, string>(); | 121 | Dictionary<string, string> param = new Dictionary<string, string>(); |
120 | param["uuid"] = uuid.ToStringHyphenated(); | 122 | param["uuid"] = uuid.ToStringHyphenated(); |
121 | 123 | ||
122 | System.Data.IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = @uuid", param); | 124 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = @uuid", param); |
123 | System.Data.IDataReader reader = result.ExecuteReader(); | 125 | IDataReader reader = result.ExecuteReader(); |
124 | 126 | ||
125 | SimProfileData row = database.getRow(reader); | 127 | SimProfileData row = database.getRow(reader); |
126 | reader.Close(); | 128 | reader.Close(); |
@@ -153,7 +155,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
153 | /// <param name="handle">The attempted regionHandle of the challenger</param> | 155 | /// <param name="handle">The attempted regionHandle of the challenger</param> |
154 | /// <param name="authkey">The secret</param> | 156 | /// <param name="authkey">The secret</param> |
155 | /// <returns>Whether the secret and regionhandle match the database entry for UUID</returns> | 157 | /// <returns>Whether the secret and regionhandle match the database entry for UUID</returns> |
156 | public bool AuthenticateSim(libsecondlife.LLUUID uuid, ulong handle, string authkey) | 158 | public bool AuthenticateSim(LLUUID uuid, ulong handle, string authkey) |
157 | { | 159 | { |
158 | bool throwHissyFit = false; // Should be true by 1.0 | 160 | bool throwHissyFit = false; // Should be true by 1.0 |
159 | 161 | ||
@@ -174,10 +176,10 @@ namespace OpenSim.Framework.Data.SQLite | |||
174 | /// <param name="authhash"></param> | 176 | /// <param name="authhash"></param> |
175 | /// <param name="challenge"></param> | 177 | /// <param name="challenge"></param> |
176 | /// <returns></returns> | 178 | /// <returns></returns> |
177 | public bool AuthenticateSim(libsecondlife.LLUUID uuid, ulong handle, string authhash, string challenge) | 179 | public bool AuthenticateSim(LLUUID uuid, ulong handle, string authhash, string challenge) |
178 | { | 180 | { |
179 | System.Security.Cryptography.SHA512Managed HashProvider = new System.Security.Cryptography.SHA512Managed(); | 181 | SHA512Managed HashProvider = new SHA512Managed(); |
180 | System.Text.ASCIIEncoding TextProvider = new ASCIIEncoding(); | 182 | ASCIIEncoding TextProvider = new ASCIIEncoding(); |
181 | 183 | ||
182 | byte[] stream = TextProvider.GetBytes(uuid.ToStringHyphenated() + ":" + handle.ToString() + ":" + challenge); | 184 | byte[] stream = TextProvider.GetBytes(uuid.ToStringHyphenated() + ":" + handle.ToString() + ":" + challenge); |
183 | byte[] hash = HashProvider.ComputeHash(stream); | 185 | byte[] hash = HashProvider.ComputeHash(stream); |
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteManager.cs b/OpenSim/Framework/Data.SQLite/SQLiteManager.cs index 3397e0d..c9931ab 100644 --- a/OpenSim/Framework/Data.SQLite/SQLiteManager.cs +++ b/OpenSim/Framework/Data.SQLite/SQLiteManager.cs | |||
@@ -27,12 +27,9 @@ | |||
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Text; | ||
31 | using System.Data; | 30 | using System.Data; |
32 | |||
33 | using System.Data.SQLite; | 31 | using System.Data.SQLite; |
34 | 32 | using libsecondlife; | |
35 | using OpenSim.Framework.Data; | ||
36 | 33 | ||
37 | namespace OpenSim.Framework.Data.SQLite | 34 | namespace OpenSim.Framework.Data.SQLite |
38 | { | 35 | { |
@@ -105,7 +102,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
105 | // Region Main | 102 | // Region Main |
106 | retval.regionHandle = (ulong)reader["regionHandle"]; | 103 | retval.regionHandle = (ulong)reader["regionHandle"]; |
107 | retval.regionName = (string)reader["regionName"]; | 104 | retval.regionName = (string)reader["regionName"]; |
108 | retval.UUID = new libsecondlife.LLUUID((string)reader["uuid"]); | 105 | retval.UUID = new LLUUID((string)reader["uuid"]); |
109 | 106 | ||
110 | // Secrets | 107 | // Secrets |
111 | retval.regionRecvKey = (string)reader["regionRecvKey"]; | 108 | retval.regionRecvKey = (string)reader["regionRecvKey"]; |
diff --git a/OpenSim/Framework/Data/GridData.cs b/OpenSim/Framework/Data/GridData.cs index 7f8fdaf..5a17d20 100644 --- a/OpenSim/Framework/Data/GridData.cs +++ b/OpenSim/Framework/Data/GridData.cs | |||
@@ -25,9 +25,7 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | 28 | using libsecondlife; |
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | 29 | ||
32 | namespace OpenSim.Framework.Data | 30 | namespace OpenSim.Framework.Data |
33 | { | 31 | { |
@@ -56,7 +54,7 @@ namespace OpenSim.Framework.Data | |||
56 | /// </summary> | 54 | /// </summary> |
57 | /// <param name="UUID">A 128bit UUID</param> | 55 | /// <param name="UUID">A 128bit UUID</param> |
58 | /// <returns>A sim profile</returns> | 56 | /// <returns>A sim profile</returns> |
59 | SimProfileData GetProfileByLLUUID(libsecondlife.LLUUID UUID); | 57 | SimProfileData GetProfileByLLUUID(LLUUID UUID); |
60 | 58 | ||
61 | /// <summary> | 59 | /// <summary> |
62 | /// Returns all profiles within the specified range | 60 | /// Returns all profiles within the specified range |
@@ -76,7 +74,7 @@ namespace OpenSim.Framework.Data | |||
76 | /// <param name="regionHandle">The regionhandle sent by the sim</param> | 74 | /// <param name="regionHandle">The regionhandle sent by the sim</param> |
77 | /// <param name="simrecvkey">The recieving key sent by the sim</param> | 75 | /// <param name="simrecvkey">The recieving key sent by the sim</param> |
78 | /// <returns>Whether the sim has been authenticated</returns> | 76 | /// <returns>Whether the sim has been authenticated</returns> |
79 | bool AuthenticateSim(libsecondlife.LLUUID UUID, ulong regionHandle, string simrecvkey); | 77 | bool AuthenticateSim(LLUUID UUID, ulong regionHandle, string simrecvkey); |
80 | 78 | ||
81 | /// <summary> | 79 | /// <summary> |
82 | /// Initialises the interface | 80 | /// Initialises the interface |
diff --git a/OpenSim/Framework/Data/ILogData.cs b/OpenSim/Framework/Data/ILogData.cs index ccb3b84..059fef5 100644 --- a/OpenSim/Framework/Data/ILogData.cs +++ b/OpenSim/Framework/Data/ILogData.cs | |||
@@ -25,10 +25,6 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | ||
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | |||
32 | namespace OpenSim.Framework.Data | 28 | namespace OpenSim.Framework.Data |
33 | { | 29 | { |
34 | /// <summary> | 30 | /// <summary> |
diff --git a/OpenSim/Framework/Data/IniConfig.cs b/OpenSim/Framework/Data/IniConfig.cs index 2f002c1..2b52fd1 100644 --- a/OpenSim/Framework/Data/IniConfig.cs +++ b/OpenSim/Framework/Data/IniConfig.cs | |||
@@ -25,12 +25,8 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | ||
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | using System.IO; | 28 | using System.IO; |
32 | using System.Text.RegularExpressions; | 29 | using System.Text.RegularExpressions; |
33 | |||
34 | /* | 30 | /* |
35 | Taken from public code listing at by Alex Pinsker | 31 | Taken from public code listing at by Alex Pinsker |
36 | http://alexpinsker.blogspot.com/2005/12/reading-ini-file-from-c_113432097333021549.html | 32 | http://alexpinsker.blogspot.com/2005/12/reading-ini-file-from-c_113432097333021549.html |
diff --git a/OpenSim/Framework/Data/InventoryData.cs b/OpenSim/Framework/Data/InventoryData.cs index 8a3a664..c2a1d06 100644 --- a/OpenSim/Framework/Data/InventoryData.cs +++ b/OpenSim/Framework/Data/InventoryData.cs | |||
@@ -25,9 +25,7 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | ||
29 | using System.Collections.Generic; | 28 | using System.Collections.Generic; |
30 | using System.Text; | ||
31 | using libsecondlife; | 29 | using libsecondlife; |
32 | 30 | ||
33 | namespace OpenSim.Framework.Data | 31 | namespace OpenSim.Framework.Data |
diff --git a/OpenSim/Framework/Data/Properties/AssemblyInfo.cs b/OpenSim/Framework/Data/Properties/AssemblyInfo.cs index 7d749d5..f9260a1 100644 --- a/OpenSim/Framework/Data/Properties/AssemblyInfo.cs +++ b/OpenSim/Framework/Data/Properties/AssemblyInfo.cs | |||
@@ -1,7 +1,5 @@ | |||
1 | using System.Reflection; | 1 | using System.Reflection; |
2 | using System.Runtime.CompilerServices; | ||
3 | using System.Runtime.InteropServices; | 2 | using System.Runtime.InteropServices; |
4 | |||
5 | // General Information about an assembly is controlled through the following | 3 | // General Information about an assembly is controlled through the following |
6 | // set of attributes. Change these attribute values to modify the information | 4 | // set of attributes. Change these attribute values to modify the information |
7 | // associated with an assembly. | 5 | // associated with an assembly. |
diff --git a/OpenSim/Framework/Data/ReservationData.cs b/OpenSim/Framework/Data/ReservationData.cs index f404ebd..0078df0 100644 --- a/OpenSim/Framework/Data/ReservationData.cs +++ b/OpenSim/Framework/Data/ReservationData.cs | |||
@@ -25,10 +25,6 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | ||
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | |||
32 | using libsecondlife; | 28 | using libsecondlife; |
33 | 29 | ||
34 | namespace OpenSim.Framework.Data | 30 | namespace OpenSim.Framework.Data |
diff --git a/OpenSim/Framework/Data/SimProfileData.cs b/OpenSim/Framework/Data/SimProfileData.cs index 201aa01..3dddfb4 100644 --- a/OpenSim/Framework/Data/SimProfileData.cs +++ b/OpenSim/Framework/Data/SimProfileData.cs | |||
@@ -25,9 +25,7 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | 28 | using libsecondlife; |
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | 29 | ||
32 | namespace OpenSim.Framework.Data | 30 | namespace OpenSim.Framework.Data |
33 | { | 31 | { |
@@ -49,7 +47,7 @@ namespace OpenSim.Framework.Data | |||
49 | /// <summary> | 47 | /// <summary> |
50 | /// OGS/OpenSim Specific ID for a region | 48 | /// OGS/OpenSim Specific ID for a region |
51 | /// </summary> | 49 | /// </summary> |
52 | public libsecondlife.LLUUID UUID; | 50 | public LLUUID UUID; |
53 | 51 | ||
54 | /// <summary> | 52 | /// <summary> |
55 | /// Coordinates of the region | 53 | /// Coordinates of the region |
@@ -109,6 +107,6 @@ namespace OpenSim.Framework.Data | |||
109 | /// <summary> | 107 | /// <summary> |
110 | /// Region Map Texture Asset | 108 | /// Region Map Texture Asset |
111 | /// </summary> | 109 | /// </summary> |
112 | public libsecondlife.LLUUID regionMapTextureID = new libsecondlife.LLUUID("00000000-0000-0000-9999-000000000006"); | 110 | public LLUUID regionMapTextureID = new LLUUID("00000000-0000-0000-9999-000000000006"); |
113 | } | 111 | } |
114 | } | 112 | } |
diff --git a/OpenSim/Framework/Data/UserData.cs b/OpenSim/Framework/Data/UserData.cs index 2e15b47..c65f9fd 100644 --- a/OpenSim/Framework/Data/UserData.cs +++ b/OpenSim/Framework/Data/UserData.cs | |||
@@ -25,9 +25,6 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | ||
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | using libsecondlife; | 28 | using libsecondlife; |
32 | 29 | ||
33 | namespace OpenSim.Framework.Data | 30 | namespace OpenSim.Framework.Data |
diff --git a/OpenSim/Framework/Data/UserProfileData.cs b/OpenSim/Framework/Data/UserProfileData.cs index ac168e0..bb7d48c 100644 --- a/OpenSim/Framework/Data/UserProfileData.cs +++ b/OpenSim/Framework/Data/UserProfileData.cs | |||
@@ -26,8 +26,6 @@ | |||
26 | * | 26 | * |
27 | */ | 27 | */ |
28 | using System; | 28 | using System; |
29 | using System.Collections.Generic; | ||
30 | using System.Text; | ||
31 | using libsecondlife; | 29 | using libsecondlife; |
32 | 30 | ||
33 | namespace OpenSim.Framework.Data | 31 | namespace OpenSim.Framework.Data |