You'll need WinMPQ to extract the campaign, and the StarCraft disc (or Brood War disc for the Brood War campaigns).
WinMPQ download:
http://shadowflare.samods.org/dwnload.html (note that you will also need the required files listed under the WinMPQ download, and a StarCraft listfile, which you should be able to find on Google).
1. Insert your StarCraft or Brood War disc.
2. Run WinMPQ
3. Click 'Options' on the menu.
4. On the new Options window that comes up, click the 'File Lists' tab.
5. Click 'Add List File'.
6. On the new Open window that comes up, navigate to your listfile, and open it.
7. Click 'Ok' on the Options window.
8. Press Ctrl+O.
9. On the new Open window that comes up, navigate to your disc and open INSTALL.
10. The scenarios will be called campaign\race\race##\staredit\scenario.chk, find the scenario(s) you want, select them, and press Ctrl+E (Brood War scenarios will be called campaign\exrace\race##\staredit\scenario.chk).
11. On the new window that comes up, navigate to the folder you want the scenario(s) in, and click 'Ok'.
12. Exit WinMPQ.
13. Open StarEdit.
14. Click the 'Open' button (or press Ctrl+O).
15. On the new Open window that comes up, navigate to the folder you extracted the scenario(s) to, and open the 'campaign' folder, and go through the folders till you get to the end (you should go down 4 folders). You will see an empty folder.
16. Type 'scenario.chk' in the 'File name:' bar, and click 'Open'.
17. And it opens.
If these instructions confused you, or it didn't work, feel free to ask.