diff options
author | BlueWall | 2012-12-09 15:08:32 -0500 |
---|---|---|
committer | BlueWall | 2012-12-09 15:08:32 -0500 |
commit | 8efae93b51082e0af9048306ffa8ca82586969af (patch) | |
tree | d320388f5a202374a2c8a9eb43b32b290e4ad920 /OpenSim/Data/MySQL | |
parent | Merge branch 'master' of /home/opensim/var/repo/opensim (diff) | |
download | opensim-SC-8efae93b51082e0af9048306ffa8ca82586969af.zip opensim-SC-8efae93b51082e0af9048306ffa8ca82586969af.tar.gz opensim-SC-8efae93b51082e0af9048306ffa8ca82586969af.tar.bz2 opensim-SC-8efae93b51082e0af9048306ffa8ca82586969af.tar.xz |
Restrict IPresenceData.VerifyAgent
Restrict IPresenceData.VerifyAgent to only return bool result
Diffstat (limited to 'OpenSim/Data/MySQL')
-rw-r--r-- | OpenSim/Data/MySQL/MySQLPresenceData.cs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/OpenSim/Data/MySQL/MySQLPresenceData.cs b/OpenSim/Data/MySQL/MySQLPresenceData.cs index 577a71a..3f90639 100644 --- a/OpenSim/Data/MySQL/MySQLPresenceData.cs +++ b/OpenSim/Data/MySQL/MySQLPresenceData.cs | |||
@@ -96,15 +96,18 @@ namespace OpenSim.Data.MySQL | |||
96 | return true; | 96 | return true; |
97 | } | 97 | } |
98 | 98 | ||
99 | public PresenceData VerifyAgent(UUID secureSessionID) | 99 | public bool VerifyAgent(UUID agentId, UUID secureSessionID) |
100 | { | 100 | { |
101 | PresenceData[] ret = Get("SecureSessionID", | 101 | PresenceData[] ret = Get("SecureSessionID", |
102 | secureSessionID.ToString()); | 102 | secureSessionID.ToString()); |
103 | 103 | ||
104 | if (ret.Length == 0) | 104 | if (ret.Length == 0) |
105 | return null; | 105 | return false; |
106 | 106 | ||
107 | return ret[0]; | 107 | if(ret[0].UserID != agentId.ToString()) |
108 | return false; | ||
109 | |||
110 | return true; | ||
108 | } | 111 | } |
109 | } | 112 | } |
110 | } \ No newline at end of file | 113 | } \ No newline at end of file |