What are the rules for right-of-way on final approach: by aircraft category or only by height?
The C172 has right of way, it's lower. The rules are in 14 CFR 91.113 and the only place where categories are mentioned is in 91.113(d), which is specifically about converging traffic at "approximately the same altitude". For landing traffic, the lower aircraft has the right of way.

People spend lots of time and energy discussing who has right of way on final, what "on final approach" really means, if it's OK to cut off a faster (or slower) aircraft, if an aircraft on a 5-mile final prevents other aircraft in the pattern from landing etc. But the discussion often becomes a bit academic: practically speaking the point is to be safe, not create any problems, and not cause other aircraft to go around or maneuver to avoid you. Think of it like pulling out of a side street in your car: if another car is coming then you shouldn't cause him to brake hard or swerve to avoid you.