def field_names(ctx, rd, field):
    '''
    Get a list of all names for the specified field
    Optional: ?library_id=<default library>
    '''
    db, library_id = get_library_data(ctx, rd)[:2]
    return tuple(db.all_field_names(field))
The application deserializes untrusted data without sufficiently verifying that the resulting data will be valid.