Intox adjustments to upstream

Please review changes from upstream