Today i want to share an article which i stumbled online. The following whole is thing is by Dan Crowley.
Advanced application-level OS fingerprinting: Practical approaches and examples
Dan Crowley
The current state of OS fingerprinting involves, for the most part, layer 3 & 4 requests and responses. This includes tools like nmap, nessus, p0f, and sinFP. These tools make specific queries and examine the response for things like TCP/IP stack settings, TCP option support, the number of syn+ack packets sent before a timeout, the time interval between syn+ack packets, and the presence of a rst packet sent at timeout. Many of these things are manipulated or deformed by intermediary devices, and much of it can be fairly easily spoofed using freely available tools like IP Personality and Security Cloak.
Application-level OS fingerprinting, on the other hand, relies on data gleaned from an application running on the target host. The current methods include the identification of OS-specific applications, such as Remote Desktop, and "banner grabbing", which involves connecting to a cross-platform application and recording what operating system it claims to be running, usually in the welcome banner (thus the name). Banner grabbing is trivial to fool, usually requiring nothing more complicated than a change in a configuration file. It's not unheard of, for instance, for Apache servers to report that they are running on a Commodore 64.
Considering this, I present an alternate approach to application-level OS fingerprinting. The general idea is that there are certain requests that can be made to cross-platform applications which result in OS-dependant responses. This can be in the form of the data returned by the application, the lack of response, or timing differences in the response, although this is almost certainly not a comprehensive list. One example of existing usage of this technique is in [5]. Based on known differences in responses and known OSes associated with specific responses, one can determine the OS of a host running a service for which such signatures exist.
There are, of course, many differences in operating systems, but only some of them are actually feasible to measure remotely (in general scenarios). Here's a non-comprehensive list:
Newline characters
==================
0x0d -> Classic Mac OS
0x0d0a -> win32, DOS, OS/2, SymbianOS
0x0a -> *nix
0x15 -> EBCDIC-based
Bit bucket
==========
/dev/null -> *nix
NUL -> Win32, DOS, OS/2
NIL -> Amiga
SYS$NULL: -> OpenVMS
*DUMMY -> Univac
Directory separator [1]
===================
backslash -> win32, OS/2, symbianOS
slash -> *nix, amiga, domain, menuet
dot -> openVMS, riscOS
colon -> Classic Mac OS
Root directory [1]
==============
/ -> *nix, menuetOS
\ -> SymbianOS
// -> Domain/OS
[drive letter]:\ -> win32, OS/2, DOS
[drive letter]:/ -> win32
[device name]: or [NODE"accountname password"]::[device name]: -> OpenVMS
[drive name]: -> Classic Mac OS, AmigaOS
[volume or assign name]: -> AmigaOS
[fs type]::[drive number or disc name].$ -> RiscOS
EOF marker
==========
0x1a -> Windows;
(int) -1 -> Pretty much everything else
Filesystem differences
======================
Maximum path length
Maximum filename length
Illegal characters
Case sensitivity
Reserved filenames, special files
***ILLEGAL NTFS CHARS***
" / \ * ? < > | :
***ILLEGAL FAT CHARS***
" + , . / : ; < = > [ \ ] | .
***ILLEGAL HPFS CHARS***
" / : < > \ |
any char below 0x20
Data alignment, word size, the existance of OS-specific binaries, and processor feature support are more criteria that can be used, but are less commonly determinable remotely.
Additionally, there are differences that are specific to an application that can be used. This varies widely from application to application, but often, these differences take one of a couple of forms. They can be vulnerabilities, or code written to patch those vulnerabilities that exist only on certain platforms (Fyodor has already discussed exploit chronology in [2] but does not discuss testing the existance of mitigation code). Certain features of programs will not be supported on some OSes, and will on others. The presence of these features eliminates unsupported OSes as a possibility. Finally, certain applications will have features which give out system details very freely. As a part of a default Apache installation, a test perl cgi script, printenv.pl, is placed in the cgi-bin directory. This script, when run, prints all environment variables. This is more or less advanced banner grabbing, but it makes a nice example of leaky features that can be found in certain applications.
But enough talk. Let's get to some real examples!
Example 1 - Apache 2.2.9
========================
http://unix.example.com/\\\.
-URL must not be URL-encoded: PuTTY or an intercepting http-proxy can be used to ensure this
-Will return a 404 Not Found error
-Unix platform
http://win32.example.com/\\\.
-Again, no URL-encoding
-Will return 200 OK and load front page
-Win32 platform
(This is an example of mitigation code that exists only on Win32 installations of Apache. Apache, when compiled for Windows, will convert backslashes to slashes. On *nix, it will not. This would work even if there wasn't specific mitigation code for Win32, but the fact that Apache on *nix doesn't change the backslashes to slashes means that backslashes will be interpreted as a part of a filename, and will just be extraneous slashes to Win32, resulting in \\\. being interpreted as a filename on *nix, and as a reference to the root dir of the website on a win32 machine.)
Example 2 - Apache 2.2.9
========================
http://unix.example.com/nul
-Returns 404 Not Found
-Not a windows based system
http://win32.example.com/nul
-Returns 403 Forbidden
-Win32
(This works because Apache won’t have read access to the bit bucket… nothing should!
On DOS-style systems, special files like nul and con “exist” and can be accessed from all directories. This should also work on other cross-platform web servers, ftp daemons, etc but I haven’t tested it)
Example 3 - Apache 2.2.9
========================
http://unix.example.com/%1a
-404 Not Found
http://win32.example.com/%1a
-403 Forbidden
(Apache on Win32 doesn’t appreciate EOF markers being stuck into URIs
Funny enough, it doesn’t like anything but GL codes(0x20-0x7f). I don’t know where in the code this happens. I think it’s likely a limitation of the system-level functions failing with characters outside a given range. Other operating systems aren’t as picky.)
Example 4
=========
http://winme.example.com/images/thumbs.db
-Has drive and pathnames in file
http://winxp.example.com/images/thumbs.db
-No drive or pathnames in file
http://xpmedia.example.com/images/ehthumbs.db
-Unique to XP Media Center
Thumbs.db
-Auto-generated image thumbnail database
-Exists in every dir with images (or certain other files) viewed in Windows Explorer with thumbnails on (even if images are later deleted)
-Generated on 98, ME, 2K, XP, 2003 (Maybe more, documentation is very sparse)
-Differs in contents between 98/ME/2K and XP/2003
-Win2k will use alternate data streams for thumbnail storage on NTFS volumes and thumbs.db on FAT partitions
-Windows XP Media Center Edition will also create ehthumbs.db for videos
(table expanded from [3])
System | Win98 | WinME | Win2k | WinXP | Win2k3
--------+---------------+---------------+---------------+---------------+---------------
Drive | Yes | Yes | Yes | No | No
Filename| Yes | Yes | Yes | Yes | Yes
Path | Yes | Yes | Yes | No | No
Last Mod| Yes | Yes | Yes | Yes | Yes
(One note about this: I was confronted with a problem with this method by Mike Eddington of Leviathan Security, who pointed out the possibility that a thumbs.db file could be uploaded to a webserver along with the corresponding images. After some thought, I realized that you could check the last modified date of the thumbs.db file as sent by the web server and the last modified date as recorded in the file. If they match, it was updated by the server itself!)
Example 5 - IIS [4]
===============
This one's pretty simple. IIS versions correspond to specific versions of Windows. Enumerate the IIS version, and you get the OS version.
IIS version | OS version
----------------+------------------
1.0 | NT 3.51 SP3
2.0 | NT 4.0
3.0 | NT 4.0 SP3
4.0 | NT 4.0 SP3
5.0 | Win2k
5.1 | XP Pro
6.0 | Server 2003
7.0 | Vista, Server 2008
(I haven't figured out ways to determine between IIS versions, although exploit chronology and feature support would likely be good candidates, and the version of IIS being reported should give a good indication. I suspect, however, that it should be easy for an admin to spoof.)
Example 6 - default FTP daemons
===============================
Run the raw ftp commands “rnfr .” and then “rnto .” against a default FTP daemon on a writable directory. It will generally spit back "350 File exists, ready for destination name" followed by a message about what happened with the operation…
OpenBSD 4.0
550 rename: Is a directory.
FreeBSD 7.0
250 RNTO command successful
OpenSolaris 2008.05
550 rename: Invalid argument.
Ubuntu 8.04 server
550 rename: Device or resource busy.
More quick examples
===================
Win32 Apache doesn’t like colons in urls, other OSes don't care so much
Win32 Apache will accept, for example, /BLAHBL~1.HTM as a valid replacement for blahblahblah.html where it will not on other OSes
(This one kinda sounds like security hell)
Other (less useful) signatures
==============================
The presence of $MFT in the root of a volume suggests an NTFS volume
Accessing a directory as a file will work on BSD systems
-FreeBSD and NetBSD will spit back binary data
-OpenBSD will return nothing but won’t complain
Windows can only use one audio input source at a time
(I came up with these too and wanted to include them for completeness, but they're so case-specific that I didn't want to give them too much time.)
If you'd like to find some signatures yourself, try grepping for #ifdef and #ifndef in the sources of any given application (if you have sources and they're C). "Linux", "BSD", "MacOS", etc are also nice candidates. Additionally, the basis for many of the examples I've given here should apply to many different applications which do similar operations or make similar system calls. Requesting nul from any application that serves or queries for files should quickly identify a Windows system.
In conclusion, application-level OS fingerprinting using multi-platform applications is possible and plausible without using banner-grabbing. OS identity info leakage in applications is not well considered (I based this on the fact that I was able to find 3 leaks with the latest version of Apache in 1 hour of searching). This method is user, and can be combined with other fingerprinting methods, which is where I feel it would be most effective, though with enough signatures, this method could stand entirely on its own.
As for further work that can be done in this field, there are definitely timing differences in application responses that could be used for OS fingerprinting. It should also be possible to find OS-version-specific responses in platform-specific applications, much like the IIS version-to-OS version example. Also, these techniques could be coded into a tool, but I'm not a great coder by any means. I hope to release some python scripts for a few of these examples shortly after the paper is released. And finally, there's more applications out there to use for fingerprinting!
Thank you for reading!
References
[1] http://en.wikipedia.org/wiki/Path_(computing)
[2] http://nmap.org/nmap-fingerprinting-article.txt
[3] http://www.acquisitiondata.com/white_papers/thumbsdbfiles.pdf
[4] http://support.microsoft.com/kb/224609
[5] http://lwn.net/2001/0222/a/sec-lpddetect.php3
To download original paper click here.
Hope all like it.
56 comments:
Very great post. I just stumbled upon your blog and wanted to
mention
that I've really loved surfing around your weblog posts. After
all I will be subscribing for your feed and I hope
you write once more soon!
Also see my web page - peergroupinitiative.wordpress.com
I am curious to find out what blog platform you have been
using? I'm experiencing some small security problems with my latest website and I'd like to find something more safe.
Do you have any
suggestions?
My page : property law zoning outline
Hello! I'm at work surfing around your blog from my new iphone 3gs! Just wanted to say I love reading your blog and look forward to all your
posts! Carry on the great work!
my page :: Tumblr.Com
Hiya! I just would like to give an
enormous thumbs up for the great information you will have here on this post.
I can be coming back to your weblog for extra soon.
My web blog - http://triaduniverse.net
Very good blog! Do you have any helpful hints for aspiring writers?
I'm hoping to start my own site
soon but I'm a little lost on everything. Would you propose starting with a free platform like
Wordpress or go for a paid option? There are so many options out
there that I'm completely
overwhelmed .. Any suggestions? Thanks a lot!
Also visit my blog ; http://www.scop.at/coppermine/displayimage.php?album=92&pos=15
Thanks a lot for sharing this with all of us you really know
what you're talking about!
Bookmarked. Kindly also visit my web site =). We could have a link exchange contract between us!
My web page :: http://Lgdato.Blogspot.ru/
Hmm is anyone else experiencing problems with the images on this blog loading?
I'm trying
to find out if its a problem on my end or if it's the blog.
Any
suggestions would be greatly appreciated.
Here is my homepage ; fiutzxq.gdmwhgaqwp.ukohkrmgnv.agjv.forum.mythem.es
I am always searching online for posts that can facilitate me.
Thx!
Also see my webpage :: http://www.ristrutturazioni-case.com
I have to convey my respect for your generosity giving support
to men and women that need assistance with that issue.
Your special commitment to getting the message
throughout has been wonderfully
practical and has consistently permitted regular
people much like me to arrive at their goals. Your entire
invaluable key points denotes a lot a person like me and far more to my peers.
With thanks; from all of us.
Here is my blog post ; cfa employment law
I am only commenting to
make you understand of the notable experience my cousin's princess encountered reading the blog. She
even learned some details, including how it is like to have a marvelous
coaching spirit to make other individuals very easily grasp several tortuous issues. You really did more than readers' expectations.
Many thanks for coming up with those warm and helpful, dependable, edifying and fun thoughts on the
topic to
Evelyn.
Here is my web page : http://www.quantockhills.com/member/422480/
It is the best time to make some plans for the future and
it's time to be happy. I've read this post and if
I could I want to suggest you some interesting things or
suggestions. Maybe you could write next articles referring to
this article. I wish
to read more things about it!
Take a look at my blog : Entitats.navas.cat
I've been surfing online more than 3 hours
today, yet I by no means discovered any attention-
grabbing article like yours. It’s pretty worth sufficient for me. Personally, if all website owners and bloggers made excellent content material as you probably did, the net will be much more helpful than ever before.
Check out my homepage : prisma-statement.org
Hello.This post was extremely interesting, particularly
because I was searching for thoughts on this subject last
Sunday.
Here is my website http://www.tempsde.punttic.cat/
Hi there! This is my first visit to your blog! We are a
group of volunteers and starting a new initiative
in a community in the same niche. Your blog
provided us beneficial information to work on. You have done a marvellous job!
Stop by my site : hossbxgiww.juvz.gooqod.zbffojuiz.wvwugy.forum.mythem.es
I’m not that much of a online reader to be honest but your blogs really nice, keep it up!
I'll go ahead
and bookmark your site to come back down the road. All the best
My page - digicube.fr
A lot of thanks for your own hard work on this site. My niece
takes pleasure in doing
research and it is simple to grasp why. Many of us know all concerning the dynamic form you
provide
powerful solutions through
the website and as well
recommend
contribution from others about this article and our
favorite simple princess is actually understanding a whole
lot. Take advantage of the remaining portion of the new year.
Your doing
a really good job.
Here is my blog ... spandau ballet gold
This is the appropriate blog for anybody who needs to find out
about this topic. You
notice so much its virtually laborious to
argue with you (not that I really would need…HaHa).
You definitely put a
new spin on a subject thats been written about for years. Nice
stuff, just
nice!
Feel free to visit my page ... sunnyside caravans kilmaurs
Definitely, what a great site and revealing posts, I will bookmark your site.
Best Regards!
Feel free to surf my web blog ; exhibicionista Santa pola
Hey! I could have sworn I've been to this website
before but after browsing through some of the post I realized it's
new to me.
Anyhow, I'm definitely glad I found it and I'll be
bookmarking and checking back
frequently!
Take a look at my weblog ... http://dlofxl.yqqtr.fcjp.iagmj.forum.mythem.es/ijruq/alarodia/bilateral/agalbanada/recedeva/muscardi/houpaard
Hi, Neat post. There's a problem with your website in internet explorer, would test
this… IE still is the market leader and a good portion of people will miss your
fantastic writing because of this problem.
Here is my web blog http://www.spainproperty.us/
fantastic points altogether, you simply gained a new reader.
What would you recommend about your post that you made some days ago?
Any positive?
Also visit my site : Moodletrainer.com
Awesome blog! Do you have any helpful hints for aspiring writers?
I'm hoping to start my own website
soon but I'm a little lost on everything. Would you
advise starting with a free platform like
Wordpress or go for a paid option? There are so many choices out there that I'm totally
overwhelmed .. Any recommendations? Cheers!
Also see my web page > http://www.nojiyan.net/mediawiki/index.php?Title=利用者:JulioShaw1971
whoah this blog is fantastic i really like reading your
posts. Stay up the great work! You already know, a lot of individuals are searching
round for this info, you could help them greatly.
Review my homepage : nz sky tv on demand
Wow! This blog looks just like my old one! It's on a totally
different subject but it has pretty much the same layout and design. Wonderful choice of colors!
Also visit my web page www.vgk-online.com
Hi! I know this is kinda off topic
but I was wondering if you knew where I could locate a captcha
plugin for my comment form? I'm using the same
blog platform as yours and I'm having problems finding one?
Thanks a lot!
My website: cqs dfi spain fund
Good post however , I was
wanting to know if you could write a litte more on this subject?
I'd be very thankful if you
could elaborate a little bit further. Appreciate it!
Also visit my website - Ewl Mundo Andalucia
WONDERFUL Post.thanks for share..more wait .. …
Also visit my web blog ; dublincore.cn
Heya i am for the primary time here. I came across this board and I in finding It
really helpful & it helped me out much. I am hoping to
provide something again and help others such as you helped me.
Check out my weblog http://www.gahzine.se
I have been surfing online more than 3 hours today, yet I never
found any interesting article
like yours. It is pretty worth enough for me.
Personally, if all website owners and bloggers made good content as you did, the internet
will be a
lot more useful than ever before.
Feel free to visit my web page ; kfc spain prices
Hello there, You've performed an excellent job. I will definitely digg it and personally recommend
to my friends. I am sure they will be benefited from this site.
Also visit my web page :: littlecamille.blogspot.fr
you're really a good webmaster. The site loading speed is incredible. It seems that
you're doing any unique trick. Moreover, The contents are masterpiece.
you have done a magnificent job on this topic!
my web page: www.catralspain.net
Whats up very cool website!! Guy ..
Excellent .. Amazing .. I'll bookmark your blog and take the feeds
additionally…I'm happy to search out numerous
useful information here within the post, we want develop more strategies in this regard, thanks for
sharing. . . . . .
Feel free to visit my blog http://wiki.rio20.net/index.php?title=Usuario:SalleyPeterson84
Hello my loved one! I want to say that this post is awesome,
nice written and include approximately all significant infos.
I’d
like to see more posts like this .
my webpage www.my.zhelide.kz
I have learn several good stuff here. Definitely price bookmarking for revisiting.
I surprise how so much effort you
place to make this type of fantastic informative website.
Here is my blog :: Yoshnet.uz
Hi there, I found your site by the use of Google while searching for a similar subject, your web site got here up, it appears great.
I've bookmarked it in my google bookmarks.
Hello there, just changed into aware of your blog through Google, and found that it is truly informative. I am going to watch out for brussels. I'll be grateful when you continue this in future.
A lot of people will be benefited out of your writing.
Cheers!
Also visit my website - weightloss shakes
I don’t even know how I ended up here, but I thought this post was
good. I don't know who you are
but definitely you are going to a famous blogger if you are not already ;) Cheers!
Here is my weblog https://translate.lorea.org
Thanks for your marvelous posting! I truly enjoyed reading it, you will
be a great author.I will make sure to bookmark your blog and
will come back at some point. I want to encourage that you continue your
great job, have a nice afternoon!
My web site ... halfproshop.com
I used to be very pleased to seek out this web-site.
I wanted to thanks to your time for this glorious read!
! I undoubtedly having fun with every
little bit of it and I have you bookmarked to check out new stuff
you blog post.
Stop by my site: HTTP://thaspace.net/
Hello there, You have done an incredible job. I will
definitely digg it and personally recommend to my friends.
I am sure they will be benefited from this site.
Here is my site ... pointofvision.org
We are a group of volunteers and starting a new scheme in our community.
Your website
offered us with valuable information to work on.
You've done a formidable job
and our whole community will be grateful to you.
Also visit my blog - http://equal.Moodle.pl/user/view.php?id=60586&course=1
We stumbled over here from a different page and thought I might as well check things out.
I like what I see so now i am following you.
Look forward to
looking into your web page again.
Also visit my homepage: www.thundershadcrankbaits.com
I do love the manner in which you have presented this challenge plus it really does present
me some fodder for consideration.
Nonetheless, through everything that I
have personally seen, I just simply
trust when other responses pile on that men and women remain
on point and not start upon a tirade involving some other news of the day.
Yet, thank you for this
outstanding point and although I
can not concur with it in totality, I value
your viewpoint.
Look into my web page - http://www.asociacionpornuestrainfancia.org/node/4587/
Hiya, I'm really glad I have found this information. Nowadays bloggers publish just
about gossips and web and this is actually frustrating. A good
website with interesting content, that is what I need. Thank you for
keeping this web-site, I will be visiting it. Do you do newsletters? Can't
find it.
Also visit my weblog; http://clubedosdescasados.com/index.php?do=/profile-26538/info/
A powerful share, I simply given this onto a colleague who was doing somewhat evaluation on
this. And he in fact purchased me breakfast as a result of I discovered
it for him.. smile. So let me reword that: Thnx for the deal with!
But yeah Thnkx for
spending the time to debate this, I really feel strongly about it and love reading
extra on this topic. If possible, as you grow
to be experience, would you mind updating your blog with more
details? It's highly helpful for me. Massive thumb up for this
blog post!
My homepage - http://ncsfd1.com
Would you be concerned about exchanging
hyperlinks?
Feel free to visit my web-site :: http://vyhid-e.org.ua
Helpful information. Fortunate me I found your site accidentally, and
I'm shocked why this accident didn't took place earlier!
I bookmarked it.
Here is my web site - easiest way to lose weight
http://watchdogsbonuscontent.blogspot.com/
Wifi Hack tool updated HACK Wireless 1 hour Click HERE
Best WiFi hack ever!:)
https://vimeo.com/74040945
Hack wifi password free WPA WPA2 WEP download software free click here,hack any wifi passwords
hack wireless internet password within 5 minutes, free download wifi hacking software
order xanax make xanax high better - xanax effects abuse
This Paypal Money Hack Tool Really Works I Just Add $2000 In My Paypal Account For Free To Download Click Here
http://bit.ly/1F9qWSm
Our software has made hacking Wifi safe and easy than ever before With a limited number of clicks wifi password. Just download http://fileml.com/file/055568K
I'm selling Western Union , Bank and Paypal Transfers all over the world. I'm getting much stuff through emails but also have a big experience in botnets etc. I've got 5 western union main computers data with the help of a strong botnet. Now I can change the info of a WU MTCN and can redirect any payment on any name. Simply I change the receiver name and country and payment goes to that person to whom i want to send. If anyone want to make big and instant money than contact me for deal.
Info needed for WU Transfers :-
1: First Name
2: Last Name
3: City
4: Country
Price List For WU Transfer:
$1500 Transfer = $150 Charges
$2000 Transfer = $300
$3500 Transfer = $450
$4500 Transfer = $500
$5500 Transfer = $600
Terms & Conditions :
A person can take transfer once in a week and maximum 2 times in a month .
If anyone want to do regular business with me then you must have many bank accounts,paypal,money bookers and fake ids for western union because after 2 or 3 transfers your paypal and Wu ids can be black listed or banned. So think before deal. Make big transactions and get a side and give other peoples chance or try to gather many fake accounts and work with me on regular basis.
You can Contact us 24/7
Contact us for deal : Email – Westernunionofficial.service@gmail.com
QUALITY SSN DOB DL HIGH CREDIT SCORES Leads
CC with CVV Fullz (USA, UK, CANADA)
Tutorials & E-Books For Ethical Hacking
Tools For Everything You Need
I'm On Telegram = @killhacks & I C Q = 752822040
Stuff available for
(Spamming, Carding, Ethical Hacking, LINUX, Programming, Scripting, etc. )
Deals in all kind of Tools, Tutorials, E-books, Leads/Fullz/Pros
Availability 24/7
FASTEST DELIVERY
Build Your Own Business with proper guide & Legit Tools
Always glad to serve
GOOD LUCK
Here I'm:
I C Q = 752822040
Tele-gram = @killhacks
Post a Comment