Multifunctional, chemically modified chitosan surfaces and charged polymer brushes with protection against microbes and changes in pH