Working detection of illegal transactions