The PerformanceResourceTiming transferSize attribute's getter steps do not account for all conditions. There are no steps for cross origin resources. In section 4.5 Cross-origin Resources, it notes that transferSize can be zero for opaque entries, which is in conflict with the getter steps previously stated.
The getter steps for the PerformanceResourceTiming transferSize should include the cross origin resource case to match with the statement in section 4.5 Cross-origin Resources. I suggest something similar to:
-
If the timing allow check algorithm fails for a cross-origin resource, then return 0.
-
If this's cache mode is "local", then return 0.
-
If this's cache mode is "validated", then return 300.
-
Return this's response body info's encoded size plus 300.
The PerformanceResourceTiming transferSize attribute's getter steps do not account for all conditions. There are no steps for cross origin resources. In section 4.5 Cross-origin Resources, it notes that transferSize can be zero for opaque entries, which is in conflict with the getter steps previously stated.
The getter steps for the PerformanceResourceTiming transferSize should include the cross origin resource case to match with the statement in section 4.5 Cross-origin Resources. I suggest something similar to:
If the timing allow check algorithm fails for a cross-origin resource, then return 0.
If this's cache mode is "local", then return 0.
If this's cache mode is "validated", then return 300.
Return this's response body info's encoded size plus 300.