Solved

Can i modify uptime of machine?

Posted on 2009-04-10
8
2,700 Views
Last Modified: 2012-05-06
Hello all,

I wanted to know if there is a way to modify a machine's uptime. For example when i issue the command     #uptime on a solaris box, is it possible to get fake results? Question goes for any OS.
0
Comment
Question by:AJKBOC
8 Comments
 
LVL 16

Expert Comment

by:ai_ja_nai
ID: 24114328
Of course yes, everything if fakeable. These programs just look up a place where the OS wrote the start date of the system on power up. You can fake the uptime program by creating a new uptime command and overwriting the old one; the new one reads the information to be displayed  from a file hidden somewhere. the user will never tell the difference
0
 
LVL 2

Author Comment

by:AJKBOC
ID: 24114372
i would need proof of that. i mean specific file, specific command.
0
 
LVL 16

Accepted Solution

by:
ai_ja_nai earned 500 total points
ID: 24114439
For every OS of the planet? Are you kidding? Every OS has its own method. Beside that, the information you want to know is not written on disk, but in RAM, so it's not even searchable.

I can give you some hints for Linux, which I know: craft a uptime program on your own, which spits out a fixed line. Find the uptime command on filesystem (it should stay on /usr/bin/uptime), rename it in uptime.old and put the fake in its place. Every time the user type 'uptime' your program will be used.

Solaris and MacOSX should work more or less the same way. Windows it's a mistery.
0
 
LVL 2

Author Comment

by:AJKBOC
ID: 24114450
of course i did not mean for every OS on the planet! Your answer though is quite acceptable and you deserve the points.
Thanks
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 48

Expert Comment

by:Tintin
ID: 24119555
I'd really like to know *why* you'd even want to do this.
0
 
LVL 16

Expert Comment

by:ai_ja_nai
ID: 24119907
ol' good time trial cracking?
0
 
LVL 2

Author Comment

by:AJKBOC
ID: 24128063
nop. online uptime contest maybe? :-)
0
 
LVL 1

Expert Comment

by:slavikn
ID: 26413469
But this won't make the 'jiffies' C command return a fake value.
Is this possible at all?
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Java performance on Solaris - Managing CPUs There are various resource controls in operating system which directly/indirectly influence the performance of application. one of the most important resource controls is "CPU".   In a multithreaded…
Ever notice how you can't use a new drive in Windows without having Windows assigning a Disk Signature?  Ever have a signature collision problem (especially with Virtual Machines?)  This article is intended to help you understand what's going on and…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now