単に sort でフィルタすればいいだけ
aaa
  $ cat trivy_sorted.json | jq "[.packages[] | {name:.name} | flatten[]] | sort"
---
Links From <- tilscb
Links To ->