Malformed data posted to fdPrivateMail through webservice deletes existing data.
Malformed data posted to fdPrivateMail through webservice deletes existing data.
When using the webservice, this request: {"method": "setFields", "id": "Python FD wrapper", "params": ["SID", "USER", "DN", {"personalInfo": {"fdPrivateMail": "{'fusk@gmail.de'}"}, "user": {"telephoneNumber": 1111, "mobile": 1111, "employeeType": "newtype"}}]}
Deletes all mail from the user.
This is a valid request: {"params": ["SID", "USER", "DN", {"personalInfo": {"fdPrivateMail": ["fusk@gmail.de"]}, "user": {"telephoneNumber": 1111, "employeeType": "newtype", "mobile": 1111}}], "method": "setFields", "id": "Python FD wrapper"}
Notice the difference in formating of the list of emails:
Invalid: {"fdPrivateMail": "{'fusk@gmail.de'}"}
Valid: {"fdPrivateMail": ["fusk@gmail.de"]}
Fix: Invalid data should be rejected, the field should not be changed. An error should be returned.
(from redmine: issue id 5292, created on 2016-12-19, closed on 2017-01-11)
- Changesets:
- Revision 6d422611 by Côme Chilliet on 2017-01-09T13:21:53.000Z:
Fixes #5292 Refuse non-array values for multivaluated attributes (should only concern webservice)
- Revision bcd1c34b by Côme Chilliet on 2017-01-09T13:23:08.000Z:
Fixes #5292 Refuse non-array values for multivaluated attributes (should only concern webservice)
- Custom Fields:
- Bug in version: 1.0.17