UserContext userContext = getPortletPropertyDescription.getUserContext();
checkUserAuthorization(userContext);
Portlet portlet = getPortletFrom(portletContext, registration);
PortletInfo info = portlet.getInfo();
PreferencesInfo prefsInfo = info.getPreferences();
List<PropertyDescription> descs = Collections.emptyList();
if (prefsInfo != null)
{
Set keySet = prefsInfo.getKeys();
descs = new ArrayList<PropertyDescription>(keySet.size());
for (Object key : keySet)
{
PreferenceInfo prefInfo = prefsInfo.getPreference((String)key);
// WSRP Spec 8.7: return only the portion of the Portlet's persistent state the user is allowed to modify
// if read only status is not determined, we consider it as being read-only to be safe
Boolean readOnly = prefInfo.isReadOnly();
if (readOnly != null && !readOnly)