Well, NZL is a little different in that you can’t sue every man and his dog everytime your stupidity blows up in your face.
They’ve had cases mentioned in NZL about freegans. My poppa used to… still does, “dumpster dive”, not for food, but for things like chairs, old electronics, he then goes and fixes them up, and on-sells them.
They were in the bin, therefore, they have no owner any more.
I see no problem with it as long as you’re not breaking into private property to get the thing, or as long as there’s no padlock on the skip. Usually the locks are to prevent people dumping stuff in them, not taking it, but it boarders on destruction of property.
Its not the sin of thieft, but I think there could be some minor venial sins of endangering your health - not just dodgey food but could be glass or nails in boards [my Poppa always checked before grabbing], or tresspass and destruction of property if you start having a go at locks.