如何在基于JS的聊天室中找到用户的IP? [英] How to find the IP of a user in a JS based chat room?
问题描述
在基于javascript的聊天室中查找用户IP的算法或代码是什么?
What is the algorithm or the code to find the IP of a user while in a javascript based chatroom?
登录到一个这样的房间,我被告知有人知道我的IP以及我正在使用的操作系统,只需在原始站点代码中插入一个简单的基于JS的代码,而不会有任何违法行为......
logging into one such room and i am told that someone knows my IP and also the OS i am using just by inserting a simple JS based code in the original site code withouth any illegal doing.....
帮助我我很好奇。
谢谢!
推荐答案
他很有可能插入一个< img>
标记,指向一个脚本,该脚本显示请求它的人的IP和用户代理。这实际上是论坛签名等中的一个常见笑话,可以让人不知道。
He most likely inserted an <img>
tag pointing to a script that displays the IP and user agent of whoever requested it. This is actually a common joke in forum signatures etc. to confuse people not knowing it.
http://www.danasoft.com/vipersig.jpg
除非脚本记录IP或他正在监视服务器的日志文件脚本位于他实际上看不到你的IP地址。
Unless the script is logging IPs or he's monitoring the logfiles of the server where the script is located he cannot actually see your IP address.
这篇关于如何在基于JS的聊天室中找到用户的IP?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!