Repository navigation
Commit db3cd20
feat: reference guardrail attachments by id and forward the folder key
Guardrail attachments are now referenced by their Orchestrator attachment id
alone: GuardrailAttachment drops the `url` field the runtime used to resolve
to a signed URL before sending it to the guardrails backend. Two problems
with that: Orchestrator's signed URL shape is environment-dependent (a
platform-proxied alpha.uipath.com URL on alpha, not *.blob.core.windows.net),
so a host allow-list downstream silently dropped every attachment; and a
caller-supplied URL meant the backend never verified the caller was entitled
to the file it fetched. The backend now resolves each id through its own
Orchestrator client, so Orchestrator's own access control applies.
evaluate_guardrail sends the optional x-uipath-folderkey header (already
defined as HEADER_FOLDER_KEY) alongside attachments when the SDK is
configured with a folder key, so the backend can resolve folder-scoped
attachments. The now-pointless URL-redaction input_processor on @Traced is
removed along with the field it protected.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>1 parent e475e89 commit db3cd20
3 files changed
Lines changed: 81 additions & 66 deletions
File tree
- packages/uipath-platform
- src/uipath/platform/guardrails
- tests/services
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | 31 | | |
51 | 32 | | |
52 | 33 | | |
| |||
125 | 106 | | |
126 | 107 | | |
127 | 108 | | |
128 | | - | |
129 | | - | |
130 | | - | |
| 109 | + | |
131 | 110 | | |
132 | 111 | | |
133 | 112 | | |
| |||
179 | 158 | | |
180 | 159 | | |
181 | 160 | | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
182 | 167 | | |
183 | 168 | | |
184 | 169 | | |
185 | 170 | | |
186 | 171 | | |
| 172 | + | |
187 | 173 | | |
188 | 174 | | |
189 | 175 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
100 | | - | |
| 100 | + | |
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
105 | 110 | | |
106 | | - | |
107 | | - | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
108 | 114 | | |
109 | 115 | | |
110 | 116 | | |
111 | | - | |
112 | | - | |
113 | 117 | | |
114 | 118 | | |
115 | 119 | | |
116 | 120 | | |
117 | 121 | | |
118 | | - | |
119 | 122 | | |
120 | 123 | | |
121 | 124 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
922 | 922 | | |
923 | 923 | | |
924 | 924 | | |
925 | | - | |
926 | 925 | | |
927 | 926 | | |
928 | 927 | | |
| |||
953 | 952 | | |
954 | 953 | | |
955 | 954 | | |
956 | | - | |
957 | 955 | | |
958 | 956 | | |
959 | 957 | | |
| |||
1000 | 998 | | |
1001 | 999 | | |
1002 | 1000 | | |
1003 | | - | |
1004 | 1001 | | |
1005 | 1002 | | |
1006 | 1003 | | |
| |||
1010 | 1007 | | |
1011 | 1008 | | |
1012 | 1009 | | |
1013 | | - | |
1014 | | - | |
| 1010 | + | |
| 1011 | + | |
| 1012 | + | |
1015 | 1013 | | |
1016 | | - | |
1017 | | - | |
1018 | | - | |
| 1014 | + | |
| 1015 | + | |
| 1016 | + | |
| 1017 | + | |
| 1018 | + | |
| 1019 | + | |
| 1020 | + | |
| 1021 | + | |
| 1022 | + | |
| 1023 | + | |
| 1024 | + | |
| 1025 | + | |
| 1026 | + | |
| 1027 | + | |
1019 | 1028 | | |
1020 | 1029 | | |
1021 | | - | |
1022 | | - | |
1023 | | - | |
1024 | | - | |
1025 | | - | |
1026 | | - | |
1027 | | - | |
1028 | | - | |
1029 | | - | |
1030 | | - | |
1031 | | - | |
1032 | | - | |
| 1030 | + | |
1033 | 1031 | | |
1034 | | - | |
| 1032 | + | |
| 1033 | + | |
1035 | 1034 | | |
1036 | | - | |
1037 | | - | |
1038 | | - | |
1039 | | - | |
1040 | | - | |
1041 | | - | |
| 1035 | + | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
1042 | 1052 | | |
1043 | | - | |
1044 | | - | |
1045 | | - | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
| 1058 | + | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
| 1064 | + | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
| 1069 | + | |
| 1070 | + | |
1046 | 1071 | | |
1047 | 1072 | | |
1048 | | - | |
| 1073 | + | |
1049 | 1074 | | |
1050 | | - | |
1051 | | - | |
1052 | | - | |
1053 | | - | |
1054 | | - | |
| 1075 | + | |
| 1076 | + | |
| 1077 | + | |
| 1078 | + | |
| 1079 | + | |
| 1080 | + | |
1055 | 1081 | | |
1056 | 1082 | | |
1057 | 1083 | | |
| |||
0 commit comments