mirror of
				https://github.com/Telecominfraproject/wlan-cloud-ucentralsec.git
				synced 2025-10-31 02:37:56 +00:00 
			
		
		
		
	WiFi 5617 and ACL Error
This commit is contained in:
		| @@ -10,6 +10,13 @@ | ||||
| #include "ACLProcessor.h" | ||||
|  | ||||
| namespace OpenWifi { | ||||
|  | ||||
|     static void FilterCredentials(SecurityObjects::UserInfo & U) { | ||||
|         U.currentPassword.clear(); | ||||
|         U.lastPasswords.clear(); | ||||
|         U.oauthType.clear(); | ||||
|     } | ||||
|  | ||||
|     void RESTAPI_user_handler::DoGet() { | ||||
|         std::string Id = GetBinding("id", ""); | ||||
|         if(Id.empty()) { | ||||
| @@ -28,9 +35,7 @@ namespace OpenWifi { | ||||
|         } | ||||
|  | ||||
|         Poco::JSON::Object  UserInfoObject; | ||||
|         UInfo.currentPassword.clear(); | ||||
|         UInfo.lastPasswords.clear(); | ||||
|         UInfo.oauthType.clear(); | ||||
|         FilterCredentials(UInfo); | ||||
|         UInfo.to_json(UserInfoObject); | ||||
|         ReturnObject(UserInfoObject); | ||||
|     } | ||||
| @@ -114,10 +119,9 @@ namespace OpenWifi { | ||||
|         } | ||||
|  | ||||
|         Poco::JSON::Object  UserInfoObject; | ||||
|         FilterCredentials(UInfo); | ||||
|         UInfo.to_json(UserInfoObject); | ||||
|  | ||||
|         ReturnObject(UserInfoObject); | ||||
|  | ||||
|         Logger_.information(Poco::format("User '%s' has been added by '%s')",UInfo.email, UserInfo_.userinfo.email)); | ||||
|     } | ||||
|  | ||||
| @@ -228,6 +232,7 @@ namespace OpenWifi { | ||||
|             SecurityObjects::UserInfo   NewUserInfo; | ||||
|             StorageService()->GetUserByEmail(UserInfo_.userinfo.email,NewUserInfo); | ||||
|             Poco::JSON::Object  ModifiedObject; | ||||
|             FilterCredentials(NewUserInfo); | ||||
|             NewUserInfo.to_json(ModifiedObject); | ||||
|             return ReturnObject(ModifiedObject); | ||||
|         } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 stephb9959
					stephb9959