UK prosecutors on Thursday defended lengthy prison sentences handed down to 16 environmental activists, telling London's Court of Appeal that their actions posed a danger to the public.