AWS – Amazon CloudFront supports header names of up to 1024 characters in CloudFront policies
Amazon CloudFront now supports a maximum of 1024 characters across all header names in cache, origin request, and origin response policies. With 1024 characters, customers now have 512 extra characters to add header metadata to their policies.
Read More for the details.