Potshot

According to Merriam Webster the term is used to describe “a shot taken from ambush at a random or easy target.” It is more commonly used to describe critical remarks made in “…a random or sporadic manner. The first known use was in 1858, and was used to describing a shot that was unsportsmanlike and only worthy of those whose only object was to fill the cooking pot.