All questions/answers/comments created by an anonymous user have a value in the cookieid column of qa_posts that can be used to join to the qa_cookies table, and thus obtain the IP address where that cookie was first used using INET_NTOA(createip), which refers to the createip column in qa_cookies.
If you want to extract this information for retrieved posts, you would need to add the following lines in qa_db_posts_basic_selectspec(...) in qa-db-selects.php:
$selectspec['source'].=' LEFT JOIN ^cookies ON ^posts.cookieid=^cookies.cookieid';
Add them *immediately* after:
$selectspec['source'].=' LEFT JOIN ^userpoints ON ^posts.userid=^userpoints.userid';
Then, you could modify qa_post_html_fields() in qa-app-format.php to make use of $post['cookieip'] and insert it wherever is appropriate, probably as a replacement for $fields['who'], for example:
if ( (!$isbyuser) && !isset($post['userid']) )
$fields['who']=qa_who_to_html($isbyuser, @$post['userid'], $usershtml, $microformats);
But the above code has not been tested...