I've noticed two tracking behaviors that don't strike me as intuitive:
- It's possible to change an IP address during a visit, but the database masks such a change because the (first) IP address is kept on the visit object and isn't even available for update.
- If you send a PHP tracking request with a bad token_auth, a visit is still logged with "erroneous" data.
- Moving IP Address (and anything else that isn't tightly coupled to the computer holding the cookie) to the visit_action
- Changing the logic for referrer to default to the submitted referrer and fallback on the last page visited (with a flag distinguishing the two).
- Certainly, one way to view this (paraphrasing current behavior) is that the caller is making a tracking API call and all token_auth does is allow the caller to submit certain "extra" (different) details.
- Practically speaking, I prefer to think of including token_auth as, first and foremost, an attempt to authenticate (that it is the tracking API is irrelevant). You can (and should) log a failed authentication (both real and reported details), but a failed authentication is fundamentally not a tracked page view.
- A "compromise" (helpful for debugging) would be to keep the submitted data as-if the token was correct (not the current strategy) and instead flag the visit/actions as "bad auth". Obviously, the "bad auth" report should include information about the submitter (for debug and blacklisting).