Securely deploying and using credentials within a script (not running the script under the credentials)

Here is my scenario - I have SCOM 2007 R2 and on certain agents I want to execute a script. One of the actions of that script is to access a secured web page using a username and password via integrated authentication (IE pop-up for auth).
The username and password that I need to use are unrelated to the Windows domain that the servers run in, meaning you can think of the website as if it were a public site (it isn't, but it has no security sharing with the domain where the agents run - no trust,
no nothing).
I can easily accomplish this by hard-coding the username and password within the script (powershell), however, I don't want to do this for security reasons. Here's a rough example of the relevant code:
$targetURL = "https://somehost.somewhere.something/filename.zip"
$path = "c:\downloads\filname.zip"
$wclient = New-Object System.Net.WebClient
$wclient.Credentials = New-Object System.Net.Networkcredential($uname, $pword)
$wclient.DownloadFile( $url, $path )
What I want is a way to pass the $uname and $pword variables to this script securely, with the script running on a schedule under SCOM. The SCOM agents run as localsystem and need to remain that way.
I currently use Run-As accounts and profiles for other functions where the entire script runs under the run-as profile, but I can't figure out how to extract the username and passwords, and doubt it's even possible.
To be clear, I cannot run the script under the given credentials as a Run-As account as those credentials are not known to the local server. I need to somehow pass the credentials to the script (other than hardcoding) or extract them from the run-as accounts.
I've looked at the get-runasaccount cmdlet and can see some of the info there, but don't see a way to re-use, pass-through, or extract the password for use in my scenario.
Any guidance? Can I get there from here?

Hi, check this
http://social.technet.microsoft.com/Forums/windowsserver/en-US/ebfc706d-93be-4ca0-83e0-33d9e072fb97/powershell-script-monitor-with-encrypted-password?forum=operationsmanagerauthoring
But you should not specify runas account for your workflow, just reference Runas Username and Password from Profile and use simple authentication. (The same way as in article above)
So in the end your script will be executed by default action account but you'll pass username and password securely to your script.

Similar Messages

  • New Security Update and now apple based programs will not run

    I recently downloaded and installed the new security update. I also attempted to download the safari 3.1 update, but an error occurred during download. After restart, iTunes, Mail, Safari, Installer and iMovie will not start (Quicktime will start). The applications from bar and from applications folder will not launch. All third party apps seem to work (I used Explorer 5.2-which I found hidden in one of my folders- to download firefox which I am using now)
    I have tried:
    -Reinstalling most recent Leopard Update (10.4.11), which fails to even start because Installer crashes
    -Deleting preference files
    -Using disk utility
    -Booting from safe mode and single user mode
    -Running repair permissions from prompt screen (command-s)
    -"Problem Report for Installer" reads:
    "Symbol not found: __ZN3KJS11Interpreter4markEv
    Referenced from: /System/Library/Frameworks/WebKit.framework/Versions/A/Frameworks/WebCore.frame work/Versions/A/WebCore
    Expected in: /System/Library/Frameworks/JavaScriptCore.framework/Versions/A/JavaScriptCore
    /System/Library/Frameworks/WebKit.framework/WebKit
    Model: PowerMac4,2, BootROM 4.4.0f1, 1 processors, PowerPC G4 (2.1), 800 MHz, 512 MB
    Graphics: NVIDIA GeForce2 MX, GeForce2 MX, AGP, 32 MB
    Memory Module: DIMM0/J12, 256 MB, SDRAM, PC133-333
    Memory Module: DIMM1/J13, 256 MB, SDRAM, PC133-333
    Modem: Dash2, UCJ, V.92, 1.0F, APPLE VERSION 2.6.6
    I searched for JavaScriptCore, and it was no where to be found. I have yet to reinstall the system software because I would like to know what caused this. I am not great with computers but I catch on quick. Please help.

    I found the java script. Hard drive>System>Library>Frameworks>Java Script Core.
    Ray

  • Interesting Document: Service Deployment  and Service Configuration  within the Internet of Things

    Hi All,
    an interesting document:
              Service Deployment  and Service Configuration  within the Internet of Things
    Best regards,
    Andy.

    Hello Marek,
    I suppose you are not planning to do any kinds of advanced config using several VLANs and multiple SSIDs so let's just make your configuration simple and working.
    In short, you need to remove all references to VLAN 1 and to any subinterfaces possibly related to the VLAN 1. This means in particular (follow these steps in sequence):
    Remove the Dot11Radio0.1 subinterface entirely
    In the Dot11Radio0 section, remove the encryption vlan 1 mode ciphers tkip command
    In the dot11 ssid ciscowifi section, remove the vlan 1 command
    After performing these steps, make sure that the ssid ciscowifi and encryption mode commands are still present in the Dot11Radio0 configuration, and if not, reenter them.
    Best regards,
    Peter

  • The buttons in main the vi get locked after opening a vi reference in a subpanel and using buttons within the subpanel.

    I am trying to open a reference to a vi in the subpanel of the main vi. However after the vi opens in the subpanel and after pressing a few buttons in the subpanel the buttons in the main vi get locked, i.e. I can't even close the main vi or control anything else. Is there any way how I can avoid this happening?

    > The buttons in main the vi get locked after opening a vi reference in
    > a subpanel and using buttons within the subpanel.
    >
    > I am trying to open a reference to a vi in the subpanel of the main
    > vi. However after the vi opens in the subpanel and after pressing a
    > few buttons in the subpanel the buttons in the main vi get locked,
    > i.e. I can't even close the main vi or control anything else. Is there
    > any way how I can avoid this happening?
    This is most likely happening because in either the top or sub panel,
    there is an event structure that is queuing events, and is set to lock
    the panel until the events are handled, and because of the logic in the
    diagram, the events aren't being pulled from the queue.
    So, you have a deadlock. You are waiting
    on the panel. The panel is
    waiting on the diagram. And the diagram is waiting on something else.
    So, if there are indeed event structures involved, determine where in
    the diagram things are delaying. Also, if you do not need the panel to
    lock until the event is handled, you can change the setting in the
    events dialog on the structure. But the events will still be queued
    until the diagram starts executing.
    Greg McKaskle

  • How to disable the security code and use only the Touch ID

    how to disable the security code and use only the Touch ID

    You can't use Touch ID without a passcode.
    http://support.apple.com/kb/HT5883

  • I've forgotten my security questions and my rescue email address is no longer available due to the address is many uears ago, what can I do for purchasing in itunes store?

    I've forgotten my security questions and my rescue email address is no longer available due to the address is many uears ago, what can I do for purchasing in itunes store?

    You won't be able to change your rescue email address until you can answer your questions, you will need to contact iTunes Support / Apple in your country to get the questions reset.
    Contacting Apple about account security : http://support.apple.com/kb/HT5699
    When they've been reset you can then use the steps half-way down this page to update your rescue email address for potential future use : http://support.apple.com/kb/HT5312

  • I forgot my Apple security questions..but the "send an email to reset your security questions and answers to rescue email" is not be available

    I have some problem with my Apple ID..I forgot my Apple security questions..but the "send an email to reset your security questions and answers to rescue email is not be available".
    I do not live in the US so I cannot call Apple Support. How else can I reset my security questions?

    The Best Alternatives for Security Questions and Rescue Mail
         1.  Send Apple an email request at: Apple - Support - iTunes Store - Contact Us.
         2.  Call Apple Support in your country: Customer Service: Contact Apple support.
         3.  Rescue email address and how to reset Apple ID security questions.
    An alternative to using the security questions is to use 2-step verification:
    Two-step verification FAQ Get answers to frequently asked questions about two-step verification for Apple ID.

  • Help, I have forgotten my Apple ID security questions and when i send it to my email address to reset the questions nothing shows up in inbox. Any other way to get past this?

    Help, I have forgotten my Apple ID security questions and when i send it to my email address to reset the questions nothing shows up in inbox. Any other way to get past this?

    Security questions:
    https://discussions.apple.com/docs/DOC-4551
    http://support.apple.com/kb/HT5312
    This is also useful:
    http://www.macworld.co.uk/ipad-iphone/news/?newsid=3463233&olo=email
    If you don’t know your security questions, phone Apple (using the number listed here:  http://support.apple.com/kb/HE57  ) and ask for the Account Security Team.

  • Had to uninstall iWork trial since I bought the pages app and it wouldn't let me print or save.  Now the app store says I have pages installed but I can't find it anywhere to open and use it.  I'm not very computer savvy and am getting frustrated!

    Ooops, guess I didn't need to post everything in the title - sorry!  I bought the pages app - but couldn't save or print so with some online searching found that I had to uninstall the iWork trial which had expired.  I did that - but now I can't figure out how to re-install the pages app!!  The app store says it's installed, but I can't find it anywhere to open and use it.  I'm not very computer savvy - and am a first time Mac user and am getting extremely frustrated!  I e-mailed some help center and they can't seem to help me either.  I would appreciate any help/advice that can fix my problem - thanks in advance!!

    OK Apple has stuffed up the demo version upgrade process so the first thing you need to do is get rid of the demo.
    That includes getting rid of the files in the system.
    The instructions how to do that are here:
    Note That where you see / that is the sequence of folders, each nested inside each other.
    User/Library/Preferences the com.apple.iwork.Keynote.plist
    Means the User (you, the little home icon, whatever you are called on your computer) then the Library folder inside that and then the Preferences folder inside that.
    Lion initially hides the System folders from you so you have to go to the Finder > Menu > hold down the option key and click on GO > Library to see it.
    Peter

  • I forgot my security code and my rescue email has been deactivated how do i reset the rescue account remember i do not remember the security codes

    I forgot my security code and my rescue email has been deactivated how do i reset the rescue account remember i do not remember the security codes

    You need to contact Apple to get the questions reset; this can be done by clicking here and picking a method for your country, or if that's not an option, by filling out and submit this form.
    (95840)

  • HT4437 I have windows seven on my computer and use Safari 5 as my browser.  I also have the latest version of apple tv...is there a way to have videos from my browsing go to apple tv?

    I have windows seven on my computer and use Safari 5 as my browser.  I also have the latest version of apple tv...is there a way to have videos from my browsing go to apple tv?

    Airparrot is your only option in my opinion. I have not tried it myself yet but here is a link to their website. They offer a trial so check it out.
    http://airparrot.com/

  • Hi,   I am trying to find out a bit more about creative cloud...  I currently use PS5 extended...  I have it on my desk top at home but travel often and use a pc. which does not have PS5 because it is licensed to mac...  So i am now thinking of using the

    hi,   I am trying to find out a bit more about creative cloud...  I currently use PS5 extended...  I have it on my desk top at home but travel often and use a pc. which does not have PS5 because it is licensed to mac...  So i am now thinking of using the cloud...  will i be able to use it on both computers? and will it work if there is slow or no internet?.

    Here are some links to general information.  IF you have specific questions feel free to ask...
    Creative Cloud Learn & Support
    http://helpx.adobe.com/creative-cloud.html
    Creative Cloud / Common Questions
    http://helpx.adobe.com/creative-cloud/faq.html
    Creative Cloud Plans
    https://creative.adobe.com/plans

  • I was running Foxfire 3.6.9 and wanted to use FTP Program add-on and it did not appear to load but appeared but then would be installed but not run or appear under tools. So I deleted Foxfire 3.6.9 and down loaded to 3.5.9 so it could get FTP and it is do

    I was running Foxfire 3.6.9 and wanted to use FTP Program add-on and it did not appear to load but appeared but then would be installed but not run or appear under tools. So I deleted Foxfire 3.6.9 and down loaded to 3.5.9 so it could get FTP and it is doing the same could not install. Even after I registered my copy. The last time I used this program it showed up under tools and worked great. any suggestions on whats going on and how I can get around this?.by ralphd3g

    Delete the files extensions.* (extensions.rdf, extensions.cache, extensions.ini) and compatibility.ini in the Firefox [[Profiles|profile folder]] to reset the extensions registry.
    See "Corrupt extension files": http://kb.mozillazine.org/Unable_to_install_themes_or_extensions
    If you see disabled extensions that are not compatible on the next start in "Tools > Add-ons > Extensions" then click the "Find Updates" button to do a compatibility check.

  • I have a iPad mini, I recently acquired a $15 iTunes card to get apps and music. I have forgotten my security questions and I cannot buy anything HELP (I tried to reset them in the Password and Security tab but the text under the questions does not show)

    I recently acquired a $15 iTunes card to get apps and music. I have forgotten my security questions and I cannot buy anything HELP (I tried to reset them in the Password and Security tab but the text under the questions does not show)

    Apple ID: Contacting Apple for help with Apple ID account security
    http://support.apple.com/kb/HT5699?viewlocale=en_US&locale=en_US
    Try the link above. Try to find a phone number for your country, call and ask for account security.

  • Is it possible to connect an external camera via bluetooth to the Iphone 4 and use it with Facetime, if not.. why?

    Is it possible to connect an external camera via bluetooth to the Iphone 4 and use it with Facetime, if not.. why?

    Ok, in 2015 is it possible now? I would like to use an iPad and Face to share content between a dressmaker in Asia and a customer in the US, and I would like to attach better camera's than the built-in camera's on the devices.
    Any thoughts? Any updates to the original post?
    Thanks,
    James

Maybe you are looking for

  • ITunes 7 gives error message when playing songs off ipod

    Whenever I connect my ipod to my computer and use itunes to play songs from it...it gives me the following message whenever a song plays. "iPod is in use and cannot be updated. The required file is in use." Does anyone know why this would be happenin

  • Help - Missing JAVA??

    Hi, I was trying to install two apps - one from OVI Store and the other from an online paying website (iguana.com.sg) for a game. When I was installing the ebuddy from OVI Store, it prompts me missing attributes. and something like "invalid Jar file"

  • Preflight flags up rotated text that is set at the specified minimum text size. Is there a way around this?

    I have set up a preflight command to flag up any text below 5pt as an error, which works fine. It doesn't flag up text at 5pt - only below... Great! However, if I have some text set also set at 5pt, yet rotated vertically, it flags it up as below 5pt

  • C1-01 not receiving text messages

    Can send text messages.  Have removed then replaced sim arnd battery.  Have reset all factory settings BUT can not receive any text messages.  No tone to alert me.  No envelope icon and nothing in the inbox.  Can any one help?

  • Exporting and Importing mail from older system

    I just upgraded my Hard Drive and OS. Was using Tiger and now Leopard. I can still access my old hard drive. How do I export my mailbox files and import them into my new sys? thx