On your length, per your description you should be OK.
504.6.1 Maximum length. The maximum length of a clothes dryer exhaust duct shall not exceed 45 feet (13 716 mm) from the dryer location to the outlet terminal. The maximum length of the duct shall be reduced 5 feet (1524 mm)
for each 45 degree (0.79 rad) bend and 10 feet (3048 mm) for each 90 degree (1.6 rad) bend. The maximum length of the exhaust duct does not include the transition duct. &e..
Table 603 4 for gage thickness
Naturally you don't want to be near as long as what is considered the OK length, but you also don't want a 2 foot run either. I don't think a couple of feet in your run will change much.
The height of the exhaust is also code;
504.6 Domestic clothes dryer ducts. Exhaust ducts for domestic clothes dryers shall be constructed of metal and shall have a smooth interior finish. With the exception of the transition duct flexible ducts are prohibited The exhaust duct shall be a minimum nominal size of 4 inches (102 mm) in diameter. The entire exhaust system shall be supported and secured in place and shall terminate not less than 12 inches (305 mm) above finished grade. The male end of the duct at overlapped duct joints shall extend in the direction of airflow. Clothes dryer
transition ducts used to connect the appliance to the exhaust duct system shall be limited to single lengths not to exceed 8 feet (2438 mm) and shall be listed and labeled for the application. Transition ducts shall not be concealed within construction and must remain entirely within the room in which the appliance is installed.
Exception: Where the duct termination is less than 12 inches (305 mm) above finished grade an areaway shall be provided with a cross-sectional area not less than 200 square feet (186m.£.) The bottom of the duct termination shall be
no less than 12 inches (305 mm) above the areaway bottom
All this and the manufacturer of your dryer is how you have to have it so if the manufacturer say shorter then it is shorter. It just cannot be longer than standards.
As for the critters, get a pest free dryer vent closure.
Code is from North Carolina, which they are using the 2006 International Mechanical Code.