The short answer is that extending a load past the cab is common, but the legality is highly dependent on the state and local regulations regarding maximum load length and visibility.
Since you are dealing with aluminum beams, they are long and rigid, wich means they are prone to shifting if not secured properly. You have to treat that overhang like a critical safety component, not just a place to park stuff for a minute. I've dealt with hauling lengths of steel and aluminum for framing jobs, and the biggest issue is the load moving when you brake or turn. To secure it, you need more than just a couple of chains. If the beams are resting parallel to the truck bed, use straps or chains anchored to both the bed rails and designated frame points behind the cab. You should have at least two heavy-duty tie-downs at the end of the load, even if the load extends past the cab, to prevent longitudinal shifting. Consider using heavy blocks or lumber placed perpendicular to the load near the cab to keep the forward movement in check. Regarding the overhang itself, you need to make sure there is absolutely zero risk of it swinging or catching anything. If the beams are high enough that they could hit a low bridge or a power line, you definatly need to use specialized load covers or banners that extend past the load to give other drivers warning. Also, check your local ordinances for 'oversize' or 'oversized' limits, as those rules will dictate if you can even run that length on public roads without a permit. If the beams are just resting on the ground and you are driving in a construction zone or on private property, the security is easier, but if you are on public roads, treat it like a high-stakes moving operation.