Install packages not in repository

It is always better to stick with packages found in the official repositories, but sometimes some software isn't available in them. To install a package that isn't found in the repositories there are different possibilities.

Download .deb

Some software offer a .deb package, to be easily installed.

Pros: no need to trust external repositories. Cons: manual updates must be done.

Add additional repositories

Some software offer additional repositories that serve debian packages of their software.
Pros: automatic updates, no missing dependencies (automatically installed). Cons: you need to trust these additional repositories.

Security warning! By adding additional repositories and gpg keys, you trust them on the same level as you trust official repositories. This mean that the maintainer of the additional repositories can easily push modified versions of the official packages that your system will completely trust (e.g. a ssh package with a backdoor). For well-known software it shouldn't be much of a concern, but be careful. See https://www.debian.org/doc/manuals/aptitude/ch02s02s05.en.html for additional information.

The general procedure is as follows: