local is_user_mgmt_priv = Input
local community_strings = cjson.json_object_new_array()
community_strings[1] = cjson.json_object_new_object()
community_strings[2] = cjson.json_object_new_object()

-- 只读团体名
community_strings[1].AccessMode = 'Limited'
community_strings[1].CommunityString = cjson.null

-- 读写团体名
community_strings[2].AccessMode = 'Full'
community_strings[2].CommunityString = cjson.null

-- 非管理员用户查看团体名时显示null
if not is_user_mgmt_priv then
    return community_strings
end

-- 隐藏团体名时也返回null
if ProcessingFlow[19].Destination.HideCommunityStrings ~= false then
    return community_strings
end

local community = ProcessingFlow[20].Destination
community_strings[1].CommunityString = community.RoCommunity
community_strings[2].CommunityString = community.RwCommunity

return community_strings