A “dangerous” paedophile who sexually abused two children and boasted online about his offending has been jailed.