Generalized principal bundles and quotient stacks