diff options
4 files changed, 25 insertions, 2 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs index 34b8114..4565d10 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs | |||
@@ -55,6 +55,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
55 | } | 55 | } |
56 | 56 | ||
57 | private string m_ProfileServerURI; | 57 | private string m_ProfileServerURI; |
58 | private bool m_OutboundPermission; | ||
58 | 59 | ||
59 | // private bool m_Initialized = false; | 60 | // private bool m_Initialized = false; |
60 | 61 | ||
@@ -78,7 +79,10 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
78 | 79 | ||
79 | IConfig thisModuleConfig = source.Configs["HGInventoryAccessModule"]; | 80 | IConfig thisModuleConfig = source.Configs["HGInventoryAccessModule"]; |
80 | if (thisModuleConfig != null) | 81 | if (thisModuleConfig != null) |
82 | { | ||
81 | m_ProfileServerURI = thisModuleConfig.GetString("ProfileServerURI", string.Empty); | 83 | m_ProfileServerURI = thisModuleConfig.GetString("ProfileServerURI", string.Empty); |
84 | m_OutboundPermission = thisModuleConfig.GetBoolean("OutboundPermission", true); | ||
85 | } | ||
82 | else | 86 | else |
83 | m_log.Warn("[HG INVENTORY ACCESS MODULE]: HGInventoryAccessModule configs not found. ProfileServerURI not set!"); | 87 | m_log.Warn("[HG INVENTORY ACCESS MODULE]: HGInventoryAccessModule configs not found. ProfileServerURI not set!"); |
84 | } | 88 | } |
@@ -103,7 +107,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
103 | public void UploadInventoryItem(UUID avatarID, UUID assetID, string name, int userlevel) | 107 | public void UploadInventoryItem(UUID avatarID, UUID assetID, string name, int userlevel) |
104 | { | 108 | { |
105 | string userAssetServer = string.Empty; | 109 | string userAssetServer = string.Empty; |
106 | if (IsForeignUser(avatarID, out userAssetServer)) | 110 | if (IsForeignUser(avatarID, out userAssetServer) && m_OutboundPermission) |
107 | { | 111 | { |
108 | Util.FireAndForget(delegate { m_assMapper.Post(assetID, avatarID, userAssetServer); }); | 112 | Util.FireAndForget(delegate { m_assMapper.Post(assetID, avatarID, userAssetServer); }); |
109 | } | 113 | } |
@@ -197,7 +201,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
197 | if (IsForeignUser(sender, out userAssetServer)) | 201 | if (IsForeignUser(sender, out userAssetServer)) |
198 | m_assMapper.Get(item.AssetID, sender, userAssetServer); | 202 | m_assMapper.Get(item.AssetID, sender, userAssetServer); |
199 | 203 | ||
200 | if (IsForeignUser(receiver, out userAssetServer)) | 204 | if (IsForeignUser(receiver, out userAssetServer) && m_OutboundPermission) |
201 | m_assMapper.Post(item.AssetID, receiver, userAssetServer); | 205 | m_assMapper.Post(item.AssetID, receiver, userAssetServer); |
202 | } | 206 | } |
203 | 207 | ||
diff --git a/bin/config-include/GridCommon.ini.example b/bin/config-include/GridCommon.ini.example index 761e5eb..e1bcf00 100644 --- a/bin/config-include/GridCommon.ini.example +++ b/bin/config-include/GridCommon.ini.example | |||
@@ -88,6 +88,10 @@ | |||
88 | ; accessible from other grids | 88 | ; accessible from other grids |
89 | ; | 89 | ; |
90 | ProfileServerURI = "http://mygridserver.com:8002/user" | 90 | ProfileServerURI = "http://mygridserver.com:8002/user" |
91 | ;; If you want to protect your assets from being copied by foreign visitors | ||
92 | ;; uncomment the next line. You may want to do this on sims that have licensed content. | ||
93 | ; OutboundPermission = False | ||
94 | |||
91 | 95 | ||
92 | [Modules] | 96 | [Modules] |
93 | ;; Choose 0 or 1 cache modules, and the corresponding config file, if it exists. | 97 | ;; Choose 0 or 1 cache modules, and the corresponding config file, if it exists. |
diff --git a/bin/config-include/HyperSimianGrid.ini b/bin/config-include/HyperSimianGrid.ini index 0b01116..89d6be7 100644 --- a/bin/config-include/HyperSimianGrid.ini +++ b/bin/config-include/HyperSimianGrid.ini | |||
@@ -82,3 +82,14 @@ | |||
82 | 82 | ||
83 | [Profiles] | 83 | [Profiles] |
84 | Module = "SimianProfiles" | 84 | Module = "SimianProfiles" |
85 | |||
86 | [HGInventoryAccessModule] | ||
87 | ; | ||
88 | ; === HG ONLY === | ||
89 | ; Change this to your profile server | ||
90 | ; accessible from other grids | ||
91 | ; | ||
92 | ProfileServerURI = "http://mygridserver.com:8002/user" | ||
93 | ;; If you want to protect your assets from being copied by foreign visitors | ||
94 | ;; uncomment the next line. You may want to do this on sims that have licensed content. | ||
95 | ; OutboundPermission = False | ||
diff --git a/bin/config-include/StandaloneCommon.ini.example b/bin/config-include/StandaloneCommon.ini.example index 4956bc3..213219c 100644 --- a/bin/config-include/StandaloneCommon.ini.example +++ b/bin/config-include/StandaloneCommon.ini.example | |||
@@ -33,6 +33,10 @@ | |||
33 | 33 | ||
34 | [HGInventoryAccessModule] | 34 | [HGInventoryAccessModule] |
35 | ProfileServerURI = "http://127.0.0.1:9000/profiles" | 35 | ProfileServerURI = "http://127.0.0.1:9000/profiles" |
36 | ;; If you want to protect your assets from being copied by foreign visitors | ||
37 | ;; uncomment the next line. You may want to do this on sims that have licensed content. | ||
38 | ; OutboundPermission = False | ||
39 | |||
36 | 40 | ||
37 | [Modules] | 41 | [Modules] |
38 | ;; Choose 0 or 1 cache modules, and the corresponding config file, if it exists. | 42 | ;; Choose 0 or 1 cache modules, and the corresponding config file, if it exists. |