A cosmetic composition for the temporary shaping of keratin-containing fibers is provided herein. The cosmetic composition includes in a cosmetic carrier, based upon the total weight of the cosmetic composition, from about 0.05 to about 2.0% by weight of chitosan or a chitosan derivative, from about 0.05 to about 2.0% by weight of a C1-C4 carboxylic acid, and from about 0.05 to about 4.0% by weight of a vinylpyrrolidone homopolymer. The cosmetic composition is free of vinyl acetate/vinylpyrrolidone copolymer and cationic cellulose compounds, which result from the reaction of hydroxyethylcellulose with a dimethyldiallylammonium reactant, or is free of vinyl acetate/vinylpyrrolidone copolymer and N-methylvinylimidazole/vinylpyrrolidone copolymer.