Re: [scim] [External Sender] Re: Error extensibility in SCIM - meeting follow up

Phillip Hunt <phil.hunt@independentid.com> Thu, 25 January 2024 19:02 UTC

Return-Path: <phil.hunt@independentid.com>
X-Original-To: scim@ietfa.amsl.com
Delivered-To: scim@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8C040C14F682 for <scim@ietfa.amsl.com>; Thu, 25 Jan 2024 11:02:47 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.803
X-Spam-Level:
X-Spam-Status: No, score=-6.803 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, HTTPS_HTTP_MISMATCH=0.1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=unavailable autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=independentid-com.20230601.gappssmtp.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XZSvbUojT2Nb for <scim@ietfa.amsl.com>; Thu, 25 Jan 2024 11:02:43 -0800 (PST)
Received: from mail-pj1-x1030.google.com (mail-pj1-x1030.google.com [IPv6:2607:f8b0:4864:20::1030]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 8333CC14F6F4 for <scim@ietf.org>; Thu, 25 Jan 2024 11:02:43 -0800 (PST)
Received: by mail-pj1-x1030.google.com with SMTP id 98e67ed59e1d1-290b37bb7deso3480539a91.0 for <scim@ietf.org>; Thu, 25 Jan 2024 11:02:43 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=independentid-com.20230601.gappssmtp.com; s=20230601; t=1706209362; x=1706814162; darn=ietf.org; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:from:to:cc:subject:date:message-id:reply-to; bh=bw8X0Dagbclx3jB8hRN/4sjpKoJ11dxDnD6cQIH8ZdE=; b=QSLUSrQFh+kTUWvLouXdhVbt7+xJF9noFBgZChvfLpCZfo2moZx6+Vhtdb4/TGT4BB YbYIn2axue5w+H7+7Ci34GQb6TocARZjQK9N9qjPa3YBsoP0bEgElMEt3poQbsZ+TBIr /N5jLnlneFF53QH1DOykeUxYa1MtfrIryHVSQPMXDFcaOB6blGOiW5Ljdtj2UQ2nGXo8 OMrPxOAoiRaIsG9z0tUDpC49O1VO2VGrkSFNZgKdtIBOtGHWY/Cebr3a+kl+UjKBYFGp 4OdeZzJ1WbJUvkBZF4pVK4katH3sqq6VTWOJR2uqkTKkt49o12efANk3ES1IOC00oaqk gaZw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706209362; x=1706814162; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=bw8X0Dagbclx3jB8hRN/4sjpKoJ11dxDnD6cQIH8ZdE=; b=twmBACMgzKEDRVkPm8vF1cYUkv56Fgt/jav064JaLptXPWDmO6wpteQl0jZ6RHLPpq pQaRTSP3aqgIZkavq/UF9zTQuKxffSs3CITZ6LcAw+fvm7PG4KezV0D5vJ+yQGOu8vZK i/toAH8udC+D4+slupoCiXX1IDcmvv6bL0XF6WU+xL0MBRaTSi7JagzskDJ9tm6qNtda CTrZ6Npr6Rsjk9KJxeFKa2vXIdpKS7XOu35fsdawZqouJxkLuKda2mhI9IG/KkEHzaJR UlUP4CctP8qvHaRTKoX+/N8wHwb9QnhayJVAwAf+9P1nzeRMDY5UsBJgRx88rN7O41qq qG6w==
X-Gm-Message-State: AOJu0Yw7yvKFZPjrez5RvMRIWstb3Tvjoqj77rwqX+q2nTNXRsI2q5L3 lau6SQRNp4vUfKQwVaFDuArKsmHgopRNrI6gz0DI8F4cPZf2iiGvYv6E8FLAquO7a23X1vFW/jy N
X-Google-Smtp-Source: AGHT+IFhe82P+qAwugRZPaoDI4YJzxMplQRUuE/77fGuhHrt6i4+ul2/BB2fuhrVTEThRKkcFLjzsw==
X-Received: by 2002:a17:90b:1651:b0:28c:93f:974d with SMTP id il17-20020a17090b165100b0028c093f974dmr60553pjb.70.1706209362195; Thu, 25 Jan 2024 11:02:42 -0800 (PST)
Received: from smtpclient.apple ([2001:569:7a96:c000:58c6:b8d6:8192:d1c1]) by smtp.gmail.com with ESMTPSA id gn20-20020a17090ac79400b0028cef021d45sm1931806pjb.17.2024.01.25.11.02.41 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 25 Jan 2024 11:02:41 -0800 (PST)
From: Phillip Hunt <phil.hunt@independentid.com>
Message-Id: <2ACDC39A-9BDE-4F2E-8746-BF37A023ACE1@independentid.com>
Content-Type: multipart/alternative; boundary="Apple-Mail=_2087BFB4-575E-4403-8FEC-3775FA74FA30"
Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.400.31\))
Date: Thu, 25 Jan 2024 11:02:31 -0800
In-Reply-To: <DEE370CC-F84A-485D-BFC0-B69079FE7748@amazon.com>
Cc: Jennifer Schreiber <jennifer.winer=40workday.com@dmarc.ietf.org>, "scim@ietf.org" <scim@ietf.org>
To: "Sehgal, Anjali" <anjalisg@amazon.com>
References: <CY4PR06MB34132DAEE819AB18D45EC76996722@CY4PR06MB3413.namprd06.prod.outlook.com> <F7CB06C8-F9E7-48DC-9BD7-6F13FC3EF779@independentid.com> <CY4PR06MB34133336A19829AB8EF4BF05967A2@CY4PR06MB3413.namprd06.prod.outlook.com> <DEE370CC-F84A-485D-BFC0-B69079FE7748@amazon.com>
X-Mailer: Apple Mail (2.3774.400.31)
Archived-At: <https://mailarchive.ietf.org/arch/msg/scim/zpsyt5Dju_H91-IvNgOita7hv0c>
Subject: Re: [scim] [External Sender] Re: Error extensibility in SCIM - meeting follow up
X-BeenThere: scim@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Simple Cloud Identity Management BOF <scim.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/scim>, <mailto:scim-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/scim/>
List-Post: <mailto:scim@ietf.org>
List-Help: <mailto:scim-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/scim>, <mailto:scim-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 25 Jan 2024 19:02:47 -0000

One of the requirements when you are cross-domain is that schema rules may be different. In general SCIM does not return errors on POST and PUT operations because one or more attributes cannot be accepted.

The lack of exact “compliance” (the result is not what was requested) could be for any number of reasons:
* formatting (e.g. the scim service provider normalized the format of a telephone number or email)
* mutability (the attribute is not modifiable by the client because the attribute is readOnly or immutable (settable once)
* not defined (the service provider does not support or understand the attribute)

None of the above may cause an error.

In this scenario, the correct way to find out what is going on is to query the /Schemas endpoint of the SCIM Service Provider.

Phil
phil.hunt@independentid.com






> On Jan 25, 2024, at 10:43 AM, Sehgal, Anjali <anjalisg@amazon.com> wrote:
> 
> Just to add on to that discussion,
>  
> I want to understand what’s the view on Error Schema Extensions.
> Suppose a SCIM server wants to improve on error messages returned how should they go about it?
> Update the description with new error? This can break existing SCIM clients who may have built some logic around the text returned.
> Release a new API version?
> Add a schema extension and allow SCIM clients to gradually transfer to using the extended error schema description field?
>  
> If there are any other mechanisms, please feel free to add.
>  
> Thanks
> Anjali.
>  
> From: scim <scim-bounces@ietf.org <mailto:scim-bounces@ietf.org>> on behalf of Jennifer Schreiber <jennifer.winer=40workday.com@dmarc.ietf.org <mailto:jennifer.winer=40workday.com@dmarc.ietf.org>>
> Date: Thursday, January 25, 2024 at 1:29 PM
> To: Phillip Hunt <phil.hunt@independentid.com <mailto:phil.hunt@independentid.com>>
> Cc: "scim@ietf.org <mailto:scim@ietf.org>" <scim@ietf.org <mailto:scim@ietf.org>>
> Subject: RE: [EXTERNAL] [COURRIEL EXTERNE] [scim] [External Sender] Re: Error extensibility in SCIM - meeting follow up
>  
> CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you can confirm the sender and know the content is safe.
> 
>  
> AVERTISSEMENT: Ce courrier électronique provient d’un expéditeur externe. Ne cliquez sur aucun lien et n’ouvrez aucune pièce jointe si vous ne pouvez pas confirmer l’identité de l’expéditeur et si vous n’êtes pas certain que le contenu ne présente aucun risque.
> 
>  
> Hi Phil – no prob.
>  
> This makes sense theoretically. I still have two use case:
> A support tech would use an errorCode or additional error details (such as a timestamp, correlation id, longform error detail etc.) to communicate with the SCIM server support human to debug.
> A SCIM client may want metrics on the errors often occurring for their requests where SCIM detail would be too granular.
>  
> I am mostly finding that the current SCIM error message is too vague, making challenging for the SCIM client to easily (machine or human) debug what is going on with their failed requests. We’ve had to rely on concatenating the error detail to put more relevant information into the response which is less than ideal.
>  
>  
>  
> From: Phillip Hunt <phil.hunt@independentid.com>
> Date: Monday, January 22, 2024 at 2:52 PM
> To: Jennifer Schreiber <jennifer.winer@workday.com>
> Cc: scim@ietf.org <scim@ietf.org>
> Subject: [External Sender] Re: [scim] Error extensibility in SCIM - meeting follow up
> 
> Jennifer,
>  
> Sorry for not getting back to this sooner. This is important. 
>  
> First, I will just zero in on your example (this may not answer your question about extending errors):
>  
> In SCIM, the expected behavior is to ignore read-only attribute updates in most cases. The best description of this is probably within the SCIM PUT.  The intent was that a relatively simply client (eg. javascript) could do a GET, change a value, and then do PUT to put the reosurce back. The value of PUT was to avoid having to pay attention to mutability.
>  
> The mutability error does apply to PATCH when the intent by the client is to “target" a read-only attribute. 
>  
> With that said, if a client (or more likely a support tech) wants to know why an attribute isn’t updating, the schema endpoint is supposed to report the actual mutability.  
>  
> ==> the reason this was done was that the collective experience of the WG at the time was that X.500 and LDAP were far too fragile by throwing errors on everything didn’t line up perfectly.  The consensus at the time was to follow Postel’s Law (aka the Robustness Principle), which boiled down meant that SCIM servers should accept requests that are understood (but not perfect), and the client must accept the response (disclosure:  I understand many in the IETF have ‘moved on’ from favouring ‘robustness'.
>  
> This use case is an example where this robustness plays out. A client doing a PUT has a bunch of attriibutes that can’t be modified but one or two that can. The server accepts the requests and updates the modified fields.  The final state is returned to the client which tells the client what was actually accepted.
>  
> —> In this way SCIM avoids the need for a lot of complex signalling and error reporting.
>  
> Let me know if this answers your question.  Or did you still have another use case for a detailed error?
>  
> Phil
> phil.hunt@independentid.com
>  
>  
>  
>  
> 
>  
> 
> On Jan 17, 2024, at 8:29 AM, Jennifer Schreiber <jennifer.winer=40workday.com@dmarc.ietf.org> wrote:
>  
> Thanks everyone for a great discussion yesterday at the meeting. We discussed error handling as relevant to scim events draft and RFC 7644.
>  
> Mainly, the big question that came up:
> Is there any extensibility method for the error messages ("urn:ietf:params:scim:api:messages:2.0:Error"), similar to Section 3.3 of RFC 7643 <https://urldefense.com/v3/__https:/datatracker.ietf.org/doc/html/rfc7643*section-3.3__;Iw!!Iz9xO38YGHZK!6D6SrM5Foas-icEjP3y9gveFMQZmfYweHP_NT89JpkM3IiHNprSv_u1objVF30Hks_nADJD9soHVSaKjusq67NXECuUiPg$>? Can error messages, as well as the other scim messages defined in Section 8.2 of RFC 7644 <https://urldefense.com/v3/__https:/datatracker.ietf.org/doc/html/rfc7644*section-8.2__;Iw!!Iz9xO38YGHZK!6D6SrM5Foas-icEjP3y9gveFMQZmfYweHP_NT89JpkM3IiHNprSv_u1objVF30Hks_nADJD9soHVSaKjusq67NUEork4lw$> be extended?
>  
> Section 3.12 of RFC 7644 <https://urldefense.com/v3/__https:/datatracker.ietf.org/doc/html/rfc7644*section-3.12__;Iw!!Iz9xO38YGHZK!6D6SrM5Foas-icEjP3y9gveFMQZmfYweHP_NT89JpkM3IiHNprSv_u1objVF30Hks_nADJD9soHVSaKjusq67NU-hbJA7w$> is a bit vague about the matter.
>  
> This came up for my internally, as the error message is not meeting my implementation needs. We're requiring an additional field, errorCode. Anjali also mentioned the need for an jsonPath field.
>  
> During the meeting, we talked through a couple ideas (that I will review in the next meeting) such as below, but we kept coming back to the same extensibility question. I wanted to open up the discussion here prior to the meeting.
>  
> ```
>    {
>      "schemas": ["urn:ietf:params:scim:api:messages:2.0:Error", "urn:ietf:params:scim:api:extension:messages:2.0:AdvancedError"],
>      "scimType":"mutability"
>      "detail":"Attribute 'id' is readOnly",
>      "status": "400"
>      "urn:ietf:params:scim:api:extension:messages:2.0:AdvancedError": {
>          "errorCode": "ABC-1235"
>      }
>    }
> ```
>  
> Thanks,
> Jen
> _______________________________________________
> scim mailing list
> scim@ietf.org <mailto:scim@ietf.org>
> https://www.ietf.org/mailman/listinfo/scim <https://urldefense.com/v3/__https:/www.ietf.org/mailman/listinfo/scim__;!!Iz9xO38YGHZK!6D6SrM5Foas-icEjP3y9gveFMQZmfYweHP_NT89JpkM3IiHNprSv_u1objVF30Hks_nADJD9soHVSaKjusq67NUjA2dxdw$>