• 0

C++ Program physically destroys computer


Question

I've been searching the internet for a while trying to find out how this is possible. My friend was programming in C++ and somehow messed with pointers or something like that.

Some of the stuff that happened after she ran her program (it was a programming project)

All her keys were randomized, some spouted the ABCs, some spouted out the less often used characters

Her computer immediately started overheating. Her computer literally started smoking within 5 minutes i believe.

My question is, how is it possible for a program to physically destroy a computer. Aren't the controls for the cooling fan, etc. protected or just plain simply built right into the motherboard or BIOS?

Thanks

P.S. I never managed to get a copy of the program from my friend seeing as how they're computer got destroyed.

22 answers to this question

Recommended Posts

  • 0

I suppose that software was not run under WinXP or any kind of protected environment... I've done same kind of software once in C++ in DOS environment.

What I did was basicly send random data to random ports (outp function).. Screen started flickering, then eventually blanked and computer shutted down.. When I started it BIOS was totaly ****ed up, password was gone, settings were all wrong and computer worked at 70% of it's previous speed. Lucky for me it was school computer... :p

Function which you ask about (fan speed etc.) I think are not protected in any matter by OS, but rather controlled by some registers in CPU.

  • 0

Look, your friend lies. It is impossible our days to destroy physically a computer with a C++ software (in the way you describe it). However, it was possible long ago (before 1992), when a virus spreaded and destroyed some bioses that weren't protected at this time.

Our days, it is absolutely impossible. The motherboard controls how much power is sent on every parts of the machine (the miracle of ATX). The mother board even controls when the power supply powers on or off. Even Windows can't bypass this protection.

There are some motherboards manufacturers that distributes overclocking softwares. These, often, can control how much voltage is given to the CPU or the Memory. The way they do this is by using assembly call to the

bios with a key to unprotect. The protection is different for every type of motherboard, and is closed source

most of the time. When it is released publicly, you must know, that the BIOS makes a validation everytime you

adjust the voltage, so you can't give more then 10 % to 20 % more power to a part (depending on the manufacturer), the bios will not accept it and the change will not occur if it is not in this range.

So, is a C++ program able to destroy one piece of hardware ? I would say it is possible if you play too much with the voltages. BUT, it is absolutely impossible to make it explode or even make it smoke. The BIOS protection prevents going over a certain temperature (it would power off the computer). If the computer started smoking, the problem comes from elsewhere. Maybe the motherboard was directly screwed on the case (you must always use little pins that prevent the motherboard from touching directly to the case).

  • 0
  Jayzee said:
I suppose that software was not run under WinXP or any kind of protected environment... I've done same kind of software once in C++ in DOS environment.

What I did was basicly send random data to random ports (outp function).. Screen started flickering, then eventually blanked and computer shutted down.. When I started it BIOS was totaly ****ed up, password was gone, settings were all wrong and computer worked at 70% of it's previous speed. Lucky for me it was school computer...  :p

Function which you ask about (fan speed etc.) I think are not protected in any matter by OS, but rather controlled by some registers in CPU.

585972690[/snapback]

yes, i think that too

in the past, i saw some program do this

but it can't do anything on Windows XP and other

  • 0

Found these simple for-printf code that can give you a nice blue screen of dread a few years back. Used to work in Win95, and surprisingly enough - XP. Works for most (if not all) 32-bit compilers in windows (tried on borland, ms, and gcc)

Yeah, i bsod-ed my own comp a few times... just for the sake of curiosity. :unsure: I've yet to see code that could affect hardware functions directly lately (At least not since my assembly days in DOS). But i remember a friend had a toshiba laptop a couple years ago that had this software to change the bios password, and some other bios stuff...

#include <stdio.h>
int main(void) {
  for (;;) {
  printf(" \t\b\b\b\b\b\b");
  }
  return 0;
}

PS: Seems harmless enough? Go ahead. You've been warned. :devil:

  • 0

SpeedFan is an example of a software where you can directly manipulate fan speeds, or turn them off if you wish, and it runs just fine under Windows XP. So if you support the motherboards you can clearly turn off all/most fans in the computer automatically without the user having to know anything. However, as others have said, your BIOS should kick in later, or even the CPU shutting down itself if it gets bad enough and you haven't configured CPU throttling/warnings in the BIOS (this isn't something that's always done).

  ThunderRiver said:
I didn't think it was possible because it is quite a high level language anyway. Who could have thought a high level language could do so much damages?

C++ isn't that high level, and you can even program assembler in it with asm {} clauses. But even without doing that, C++ is fully usable to write e.g. device drivers with and in these cases bad pointers or other things can really mess things up. :)

Edited by Jugalator
  • 0
  tx83 said:
Look, your friend lies. It is impossible our days to destroy physically a computer with a C++ software (in the way you describe it). However, it was possible long ago (before 1992), when a virus spreaded and destroyed some bioses that weren't protected at this time.

Our days, it is absolutely impossible. The motherboard controls how much power is sent on every parts of the machine (the miracle of ATX). The mother board even controls when the power supply powers on or off. Even Windows can't bypass this protection.

There are some motherboards manufacturers that distributes overclocking softwares. These, often, can control how much voltage is given to the CPU or the Memory. The way they do this is by using assembly call to the

bios with a key to unprotect. The protection is different for every type of motherboard, and is closed source

most of the time. When it is released publicly, you must know, that the BIOS makes a validation everytime you

adjust the voltage, so you can't give more then 10 % to 20 % more power to a part (depending on the manufacturer), the bios will not accept it and the change will not occur if it is not in this range.

So, is a C++ program able to destroy one piece of hardware ? I would say it is possible if you play too much with the voltages. BUT, it is absolutely impossible to make it explode or even make it smoke. The BIOS protection prevents going over a certain temperature (it would power off the computer). If the computer started smoking, the problem comes from elsewhere. Maybe the motherboard was directly screwed on the case (you must always use little pins that prevent the motherboard from touching directly to the case).

585972735[/snapback]

my friend wasn't lying. I saw the computer after it was destroyed. Plus they have no reason whatsoever to lie. Lie for an interesting story, no, she had more than enough interesting stories. She ran the program on Windows XP, by the way. The maker of the computer was Sony, it was a laptop.

Like I said before, this is what really baffles me. How does a computer overheat from a program? (And don't try to work off the lieing angle) My friend still has the destroyed computer. One of these days, I'm going to get that hard drive and get the contents off it. In the mean time, I'm hoping some of you could provide a definitive answer.

Perhaps there is a problem with the BIOS on that particular motherboard that Sony failed to detect and she accidentally stumbled across it.

  • 0

Now that I think about it, BIOSs can be updated to a certain extent, right? I'm not sure how far you're allowed to edit the BIOS before you need to send it to a manufacturer to update. Maybe her program edited the BIOS but still stayed in the bounds.

Just a theory.

Just to answer any extra questions. The computer merely smoked, it didn't explode. She never tampered with the hardware of the computer. I mean it's a laptop, you can't really do all that much if you open it up.

  • 0

If the computer was destroyed from heat, it probably had a heat problem to begin with. The program or wahtever it was just caused high CPU usage, which in turn caused more heat, and if the heatsink was unable to cope with the heat the computer either shut off or died.

  • 0

Some motherboards allow you to overclock from within windows. It could've been one of two things. Either the program she was making caused her laptop to just overheat at stock temps, or the program could've somehow actually overclocked the CPU to the point of no return. I'm not sure what intel boards can do this, I am familiar with nvidia-based chipsets having such features.

  • 0
  nomis_nehc said:
heh, i think your friend is bs'ing too. from what i know of c++, it doesn't seem possible today.

585974791[/snapback]

may seem impossible but think about computers. The stupidest retard (no offense to them) is still smarter than the world's smartest computer, even that Honda robot. Do you know why? Because a computer lacks any common sense and doesn't assume what you want. It's quite possible that in programming the BIOS, the programmers overlooked a special case scenario which normally doesn't happen.

Before we start saying that all these programmers have master's in yada yada, they're still human and by nature, they will naturally assume the computer knows what they want and will do that.

When I go off to college, my friend will be relatively close so I'll see if I can grab the laptop's hard drive supposing it wasn't damaged too badly. But rest assured, my friend is no BSing and neither am I.

  • 0
  bubbleboys said:
may seem impossible but think about computers.  The stupidest retard (no offense to them) is still smarter than the world's smartest computer, even that Honda robot.  Do you know why?  Because a computer lacks any common sense and doesn't assume what you want.  It's quite possible that in programming the BIOS, the programmers overlooked a special case scenario which normally doesn't happen.

Before we start saying that all these programmers have master's in yada yada, they're still human and by nature, they will naturally assume the computer knows what they want and will do that.

When I go off to college, my friend will be relatively close so I'll see if I can grab the laptop's hard drive supposing it wasn't damaged too badly.  But rest assured, my friend is no BSing and neither am I.

585975135[/snapback]

You have a somewhat simplistic view of modern day computers. In the past there have been design flaws (or simply insufficient safeguards) that allowed physical damage (prime example.... setting the refresh rate of a monitor too high) but those days are long past unless you're talking about some very old or some very esoteric computer equipment.

In this case, either your friend is BS'ing YOU, YOU are BS'ing US or, as Weenur pointed out, it's coincidence.

  • 0

Well it's entirely possible to access registers on your chipset (and just about any other device). For example, on VIA KT266A and KT333 systems you can enable two flip-flops that enable the "halt" instruction for the CPU. This is disabled by the bios on boot probably because this feature wasn't bug-free. Depending on the quality of the hardware it could be possible to make things burn and fry. For example, if two pins are connected and they both try to drive a signal (let's say pin a is a 1 and pin b is a 0) then we could have some problems.

It is highly unlikely though. Safeguards are built into standards and other safeguards are are put in place without even thinking any more. Engineers do get lazy though especially when managers are bitching about product releases.

  • 0
  Andareed said:
You can write a kernel driver to do anything windows does. So the question should be if the processor allows such action.

585974781[/snapback]

You can only write a kernel mode application by getting a special SDK from microsoft, which you have to sign a license agreement in writing, in Redmond. The DDK that you can get for free can only make device drivers, in which case still cannot damage the system even if malprogramed because Windows still has total control over the system.

In NT (NT, 2000, XP, 2003, Longhorn), you cannot do such, as the OS is in protected mode which means that you cannot access physical memory thru your apps, and there is not bug in this. You cannot access any of the stuff that the OS can (BIOS, chipset, raw hardware access), unless you have a kernel mode application. It is much more complicated than I can explain to someone who thinks C++ on WinXP can destroy a computer, so I will leave it at that.

  • 0
  b0b said:
You can only write a kernel mode application by getting a special SDK from microsoft, which you have to sign a license agreement in writing, in Redmond. The DDK that you can get for free can only make device drivers, in which case still cannot damage the system even if malprogramed because Windows still has total control over the system.

In NT (NT, 2000, XP, 2003, Longhorn), you cannot do such, as the OS is in protected mode which means that you cannot access physical memory thru your apps, and there is not bug in this. You cannot access any of the stuff that the OS can (BIOS, chipset, raw hardware access), unless you have a kernel mode application. It is much more complicated than I can explain to someone who thinks C++ on WinXP can destroy a computer, so I will leave it at that.

585981996[/snapback]

But AFAIK, windows device drivers (made using the DDK) run in ring 0, just like the kernel and so you can do many stupid things like change the PDBR or IDT entries.

  • 0
  bubbleboys said:
may seem impossible but think about computers.  The stupidest retard (no offense to them) is still smarter than the world's smartest computer, even that Honda robot.  Do you know why?  Because a computer lacks any common sense and doesn't assume what you want.

retards have common sense?

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Lifetime subscription to Mail Backup X gets price dropped by 72% by Steven Parker Today's highlighted deal comes via our Apps + Software section of the Neowin Deals store, where you can save 72% off a lifetime subscription to Mail Backup X Individual. For most individuals and organizations, emails are the most critical part of daily activities and communications. Some of us realize the importance of backing up emails only when critical emails are lost for some reason. Plan ahead and safeguard your mail data today with a robust and reliable mail backup solution. Mail Backup X is a one-stop solution for mail backup, archiving, email management & mail conversion trusted by 42,000+ business and home users worldwide. Backup from major mail clients. Apple Mail, Microsoft Outlook, Office 365, Microsoft Exchange, Thunderbird, Postbox Backup from mail services. Gmail, Outlook.com, Yahoo, Gmx.de, Office365, Microsoft Exchange, or any service supporting IMAP protocol Archive file viewer. Quickly search & view your emails from archives Highly compressed archives. Save up to 3x storage space Import almost any mail archive. Files like .pst, .ost, .mbox, .olk, .eml, .rge, and more Mirror backup. Cloud storage (Google Drive, One Drive, Dropbox, Pcloud or FTP) or USB drive Restore. Restore direct to the server account or a separate server account Migration. Move all mails onto a new account in Office365 100% privacy. Encrypt & secure your data with military-grade aes 256-bit encryption and your own private key, so it's only visible to you Top-notch premium support. Get help that you need from experts Good to know Plan: Individual Edition Length of access: lifetime Redemption deadline: redeem your code within 30 days of purchase Access options: desktop Max number of devices: 2 Only available to new users Version: 2 Updates included A lifetime subscription to Mail Backup X normally costs $179, but you can pick this up for just $49.99 for a limited time - that represents a saving of $129 (72% off). For a full description, spec, and terms, click the link below. Get Mail Backup X (lifetime plan) for just $49.99 (was $179) Use coupon code SAVE20 at checkout to get this product for an additional 20% off We post these because we earn commission on each sale so as not to rely solely on advertising, which many of our readers block. It all helps toward paying staff reporters, servers and hosting costs. Other ways to support Neowin Whitelist Neowin by not blocking our ads Create a free member account to see fewer ads Make a donation to support our day to day running costs Subscribe to Neowin - for $14 a year, or $28 a year for an ad-free experience Disclosure: Neowin benefits from revenue of each sale made through our branded deals site powered by StackCommerce.
    • I will believe it when it happens. iOS 18 was heavily rumoured to be a massive overhaul with visionOS glass style UI elements. Never happened. I don't even believe the x26 naming scheme is real either, feels more like an April fools joke *shrugs* I'll be happy to be proven wrong. However, till Apple themselves say it's so I will remain skeptical.
    • Nothing Phone (2a) hits a sweet spot: Is this mid-ranger the best value for your money? by Paul Hill Are you in the UK and looking for a smartphone with a standout design, solid display, good battery life, and smooth software? Then the Nothing Phone (2a) stands out as a solid mid-range option, especially considering it’s discounted 36% from £349 to £222. To clarify, this is the 12GB+256GB Nothing Phone (2a), not the weaker 8GB+128GB model. I’ll cover what’s included with this phone, but if you’re convinced to pick it up, be aware that this is marked as a limited-time deal so don’t sit on your hands. What the Nothing Phone (2a) delivers (and where it stands out) Powering the Nothing Phone (2a) is a mid-range Mediatek Dimensity 7200 Pro processor, 12GB of RAM with an 8GB RAM booster, and an advanced cooling system to boost game performance and longevity. In terms of battery life, the Nothing Phone (2a) packs a 5,000 mAh battery that will keep the device running for up to two days. When the battery does drain, you have 45W fast charging which will take 40 minutes to get you to 100% battery. On the back of the phone there is a 50 MP Main (OIS & EIS) camera as well as a 50 MP ultra-wide camera. On the front, you get a 32 MP camera. This phone tries to punch above its weight with the camera with features like Ultra XDR and Portrait Optimiser. The display is pretty good too, it includes a 6.7-inch AMOLED with 1,300 nits peak brightness and 120Hz adaptive refresh rate. This screen is ideal for gaming with its higher refresh rate and that cooling system I mentioned earlier will help it keep chugging along nicely. This phone came out in the first half of 2024, so you may be wondering what the software situation is. It initially shipped with Nothing OS 2.5 which is powered by Android 14, but this has since been upgraded to Nothing OS 3.0, powered by Android 15. Nothing has promised three major OS upgrades for this device, but one has been used up so expect Nothing OS releases based on Android 16 and Android 17 in the coming years. For those not familiar with Nothing OS, it has a strong reputation for being clean, smooth, and well-optimised, with little to no bloatware. If you’re coming from a brand like Xiaomi which packs its devices with bloatware and even ads, then the Nothing Phone (2a) should feel very clean. Finally, environmentalism has come more into focus over the last decade and while buying a second hand phone is best, Nothing has made decent efforts with this device by using recycled materials to keep the carbon footprint low. Should you buy it? At £222, the Nothing Phone (2a) is significantly reduced in price, making it a solid option for people looking for a mid-range device. If you like the unique design, clean software, good camera, and a strong battery life, then this device is definitely for you. The deal is marked as a limited-time deal and Amazon has marked it as an Amazon Choice suggesting that it’s a good phone to buy. It’s also at its lowest price, so you definitely aren’t paying over the odds. If you’re convinced, check the buying link below! Nothing Phone (2a): £222 (36% off) / MSRP: £349 This Amazon deal is U.K. specific, and not available in other regions unless specified. If you don't like it or want to look at more options, check out the Amazon UK deals page here. Get Prime, Prime Video, Music Unlimited, Audible or Kindle Unlimited, free for the first 30 days As an Amazon Associate we earn from qualifying purchases.
    • "It will have curved glass sides around the entire phone, even at the edges." Will it be just a collectible? I can't imagine myself having a glass phone. I'd gladly exchange glass back panel for plastic or aluminium on mine.
  • Recent Achievements

    • Week One Done
      Al_ earned a badge
      Week One Done
    • Week One Done
      MadMung0 earned a badge
      Week One Done
    • Reacting Well
      BlakeBringer earned a badge
      Reacting Well
    • Reacting Well
      Lazy_Placeholder earned a badge
      Reacting Well
    • Dedicated
      Epaminombas earned a badge
      Dedicated
  • Popular Contributors

    1. 1
      +primortal
      477
    2. 2
      +FloatingFatMan
      274
    3. 3
      ATLien_0
      243
    4. 4
      snowy owl
      208
    5. 5
      Edouard
      182
  • Tell a friend

    Love Neowin? Tell a friend!