list only third party packages in Ubuntu 18.04

I am Creating a project to view and upgrade packages in Ubuntu. Is there any command for list only Third party software?

dpkg --list shows all packages installed in OS.


To list the packages installed from third-party repositories:

ubuntu-security-status --thirdparty 

To list the locally installed or obsolete packages missing from any enabled repository:

ubuntu-security-status --unavailable

To further check the specifics, type in:

apt-cache policy <package_name>