How to sign a profile via Script

Hi,
i have managed an internal Website on which a User can log in with his Active Directory Account. The Site is looking for his phone number in the AD and an additional "AirTerminal" account for his phone number. If everything is ok, the User has the choice to select iPhone or Windows Mobile. After the choice he can push a button "Send Configuration".
The Configuration will be sent out to his phone with a SMS which includes a One-Time-URL. This One-Time-URL can, of course, be used only once, after that the URL will not work anymore.
The URL contains a File, specially for this particullary user, preconfigured with his E-Mail, Domain and Username. After the Profile is installed, the User is only be prompted to supply his Windows Password for Exchange.
This is working fine!!! We do not have any problems with this kind of deployment and the Users like it.
The only thing disturbing is the "Unsigned" showing up in the Profile. We would like to sign this Profile and really do not want to use the ICU or SCEP and so on. Our solution is completely independent of infrastructure. The solution can be used with any kind of LDAP. So no need fpr Microsoft AD and so on...
How can this be resolved with scripting like shell, bash, php or whatever...
Could be that there is one time, and we will be kick off Microsoft, or whatever...
Kind regards
Stefan

setPageBoxes() :
But the contents do not fit to the page size.
How to resize the contents to fit to the page size?

Similar Messages

  • How to Perform File- Place via Scripting (CS5)

    Hi all,
    Photoshop contains the option of directly placing one graphic file onto the currently active layer via the menu with File-> Place.
    How do I do this in scripting?
    TIA,
    mlavie

    @xbytor2: Thanks for the quick response.
    I noticed that File->Place does not bring the image's clipping path along with the image. Does your example do that, and if not, would you have any idea how?
    TIA,
    mlavie

  • How to get DP name via script

    Hello,
    We are migrating from Symantec Altiris to SCCM 2012. In our current environment we have both HP models and now moving towards Lenovo models. We are using both respective Enterprise solutions for managing driver that is HP SSM and Lenovo Thininstaller.
    We have 3 sites/locations with exactly the same shares on each one. We are using a script with a built in Altiris token that finds out what DP or Taskserver (in Altiris Environment) the client is connected to.
    How can I define a DP with the same type of script in SCCM?
    Are there any tokens for DP?
    Are there any specific local files or usuble values that changes when connecting to other DPs?
    Can I somehow query bounderies in a script and then use IF statement to connect them to a specific share?
    I know that I can use one share if I want to but that will use a lot of network trafic since we have the DPs on different locations throughout the country. One idea I had was to make 3 different packages with one DP specified in each
    one and then connect them to its specific boundary.  
    The good part to make it work all in one script is that it can be applied to any client in the organisation to update their current drivers and not just to use in initial deployment.
    I found a vbs script that can echo a DP, but how do I implement it into my script?
    http://sccmguru.wordpress.com/2014/04/22/show-dp-in-use-during-task-sequence/
    '// Purpose: Used to find active Distribution Point
    '// Version: 1.0 - April 15, 2014 - Odd-Magne Kristoffersen
    '// This script is provided "AS IS" with no warranties
    Set env = CreateObject("Microsoft.SMS.TSEnvironment")
    ENV_SMSTSHTTPTHI0000D = env("_SMSTSHTTPTHI0000D")
    SMSTSHTTPTHI0000D = Split(ENV_SMSTSHTTPTHI0000D,"/",-1,1)
    DP = split(SMSTSHTTPTHI0000D(2),".",-1,1)
    Echo DP(0)  
    Here is my script in short format. I didn't bother putting all the models.
    The value %MODEL% is from the Query in the beginning of the script and the %TASKSERVER% value is an Altiris token the can be used when running a script with the agent credentials.
    @echo off
    set model=
    FOR /F "tokens=2 delims='='" %%A in ('wmic ComputerSystem Get Model /value') do SET model=%%A
    Echo This is a %MODEL%
    IF "%MODEL%" == "HP EliteBook 820 G1" GOTO HP Updates
    IF "%MODEL%" == "HP EliteBook 840 G1" GOTO HP Updates
    IF "%MODEL%" == "HP Compaq 8000 Elite SFF PC" GOTO HP Updates
    IF "%MODEL%" == "HP Compaq 8100 Elite SFF PC" GOTO HP Updates
    IF "%MODEL%" == "HP Compaq 8200 Elite SFF PC" GOTO HP Updates
    IF "%MODEL%" == "HP Compaq Elite 8300 SFF" GOTO HP Updates
    IF "%MODEL%" == "20AQ007UMS" GOTO Lenovo Updates
    IF "%MODEL%" == "20AL00BYMS" GOTO Lenovo Updates
    IF "%MODEL%" == "10AB000YMX" GOTO Lenovo Updates
    IF "%MODEL%" == "20C0003TMS" GOTO Lenovo Updates
    IF "%MODEL%" == "20AL007NMS" GOTO Lenovo Updates
    IF "%MODEL%" == "10AAS0HN00" GOTO Lenovo Updates
    exit 1
    :Hp Updates
    \\%TASKSERVER%\Share\ssm.exe \\%TASKSERVER%\Share /ACCEPT /INSTALL /DEBUG /TITLE:"HP Updates" /NOREBOOT
    RMDIR "c:\ssm" /s /q
    exit 0
    :Lenovo Updates
    xcopy \\%TASKSERVER%\Share\Thininstaller c:\Thininstaller /S /H /I /Y
    c:\Thininstaller\Thininstaller.exe /CM -search A -action INSTALL -repository \\%TASKSERVER%\Share\Repository-noicon -includerebootpackages 0,3 -showprogress -noreboot
    RMDIR "c:\Thininstaller" /s /q
    exit 0

    The way these two driver management systems work is that the exe is not installed, only executed with different switches to look inside a share with drivers to match what is installed on the client and apply the missing drivers.
    I have checked other threads with HP ssm and Lenovo Thininstaller regarding SCCM implementation and they all create a package for the exe and apply the command switches. Exactly as many of you already described here.
    That works if you have only ONE share. I manage 3 shares, one for each geographical location that we prep Windows installations. This to make it faster for the client to download the drivers and to not use/load the WAN unnecessarily.
    I read on another thread that I can't query a dp because it's assigned only when the client requires content. 
    The only workaround as I see it is to:
    1. Create 3 different packages with different  shares in the command line. And somehow apply a detection method in the task sequence to figure out location (DP, IP, DNS, boundary, Assigned Domain Controller).
    2. Create 3 different packages and 3 different roles in MDT, one for every location. 
    3. Only use one share on the location that mostly is used for Windows installations and accept that it will take longer for the drivers to be applied on the other locations. 
    Which one should I go for?
    Many of you may think that I should use the standard way of managing drivers in SCCM. But this is so much easier. I never have to package drivers or hardware applications like HP Connection Manager. I can reapply the package to any client in production and
    update the drivers and model specific applications if needed.

  • How to edit a plist via script in OSX 10.7+

    With the changes made to Lion, with regards to LDAP authentication, I find myself having to edit the my-ldap-server.plist in /Library/Preferences/OpenDirectory/Configurations/LDAPv3/ manually in Xcode at every install; specifially I need to add some entries to the "Denied SASL Methods" array. I think I can do this with PlistBuddy, but am having problems figuring it out. Copy/Paste from terminal, some items editted to protect the guilty. Here's what I see:
    backuplt1:Desktop user1$ /usr/libexec/PlistBuddy ldap.test.org.plist
    Command: print
    Dict {
        node name = /LDAPv3/ldap.test.org
        module options = Dict {
            AppleODClient = Dict {
                Server Mappings = true
            ldap = Dict {
                Use DNS replicas = false
                Denied SASL Methods = Array {
                    DIGEST-MD5
                LDAP Referrals = false
        description = ldap.test.org
        options = Dict {
            man-in-the-middle = false
            connection setup timeout = 10
            destination = Dict {
                other = ldap
                host = ldap.test.org
                port = 389
            packet encryption = 2
            no cleartext authentication = false
            packet signing = 0
            query timeout = 30
            connection idle disconnect = 60
        template = Open Directory Server
    Any thoughts?

    I couldn't see PlistBuddy in /usr/libexec for some reason; must be hidden? Anyway, it's there and I foiund this site to help here:
    http://blog.smalleycreative.com/administration/fixing-openldap-authentication-on -os-x-lion/
    sudo su
    /usr/libexec/PlistBuddy -c "add ':module options:ldap:Denied SASL Methods:' string CRAM-MD5" /Library/Preferences/OpenDirectory/Configurations/LDAPv3/yourldapserver.plist
    /usr/libexec/PlistBuddy -c "add ':module options:ldap:Denied SASL Methods:' string NTLM" /Library/Preferences/OpenDirectory/Configurations/LDAPv3/yourldapserver.plist
    /usr/libexec/PlistBuddy -c "add ':module options:ldap:Denied SASL Methods:' string GSSAPI" /Library/Preferences/OpenDirectory/Configurations/LDAPv3/yourldapserver.plist
    Hope this helps others.

  • OSX 10.9 Maverick add a LDAP server via script

    I use applescript to add a LDAP sever on 10.8, but after the 10.9 released, I found the script cannot use any more.
    Seems is the new Mail app doesn't support LDAP sever , it is integrated to Internet Accounts
    However the SAMPLE script is still the same. (  /Library/Scripts/Mail\ Scripts/Create\ New\ LDAP\ Server.scpt )
    Does any one know how to config internet accounts via script (BASH script is OK too)?
    the new mail app does not understand
    make new ldap server with properties {name:theName, host name:theAddress, search base:theSearchBase, Çclass ldpoÈ:thePort, scope:theScope}
    any more.

    I'd first read the subject and thought this involved creating an entire LDAP server via script and thought... whoa, that's some script.    
    But you're seeking to reference a remote resource or some automated way to configure your client mail, and that's currently using LDAP, right?  If so, then Apple has shifted over to Profiles and away from LDAP and MCX and related.  Profiles would be the approach I'd follow here, either with OS X Server and its profile manager or some other MDM service.
    If you have access to the Apple WWDC13 session videos, there's a session on the Profile Manager that might be worth your time.

  • ODI 11g - Work Repository Creation via Script

    Hi!
    Do you have any suggestions how to create work repositories via script?
    My idea is to create all database objects in the schema for the new work repository and insert the repository specific information into the tables
    - SNP_REM_REP (master repository)
    - SNP_CONNECT (master reppository)
    - SNP_LOC_REPW (work repository)
    Am i missing something?
    Thanks in advance & kind regards
    Michael

    Why do you want to do it this way ?
    I dont think your idea is going to work as there are 87 other tables (maybe not all of them) in Work Rep that need to be populated. And only the Work repository creation menu in the Topology would do it for you. There are relationship among those tables that need to be satisfied.
    What version are you on ? In 11g you can write Java code to do the things I mentioned above. Whatever you can click and do in 10g can be done using Java programming in 11g.

  • Howto: Determine Image Offset via Scripting?

    Given the screengrab, below,
    How would I go about, via scripting (js), fetching the "X+" value? Is it a calculation of other values, and if so, what are they?
    I want to get that "7.2" value.
    Thanks.

    app.selection[0].graphics[0].geometricBounds[1]-app.selection[0].geometricBounds[1]

  • How to find a text in the Frame maker document via script?

    How to find a particular text in the Frame maker document via script?

    johnsyns wrote:
    Why it doesn't work for the other days? When i tried to change the days other than wednesday. it return nothing.
    Reason why Justin's code does not work for other days is date format mask DAY returns day blank padded to 9 characters which is the longest day name which, yes you guessed right, is WEDNESDAY. You either need to blank pad or use format modifier FM:
    SQL> select *
      2    from (SELECT TO_DATE(SYSDATE+ROWNUM, 'DD-MON-YY') dt
      3            FROM DUAL CONNECT BY ROWNUM <= 27)
      4  WHERE TO_CHAR(dt,'DAY') = 'TUESDAY'
      5  /
    no rows selected
    SQL> select *
      2    from (SELECT TO_DATE(SYSDATE+ROWNUM, 'DD-MON-YY') dt
      3            FROM DUAL CONNECT BY ROWNUM <= 27)
      4  WHERE TO_CHAR(dt,'DAY') = 'TUESDAY  '
      5  /
    DT
    07-APR-09
    14-APR-09
    21-APR-09
    28-APR-09
    SQL> select *
      2    from (SELECT TO_DATE(SYSDATE+ROWNUM, 'DD-MON-YY') dt
      3            FROM DUAL CONNECT BY ROWNUM <= 27)
      4  WHERE TO_CHAR(dt,'FMDAY') = 'TUESDAY'
      5  /
    DT
    07-APR-09
    14-APR-09
    21-APR-09
    28-APR-09
    SQL> SY.

  • How can I change the default search provider from yahoo to google via script?

    I have 350 users who are upset about the default search provider being changed. I need to change it back via script. How do I do this? I have attempted lockPref("browser.search.isUS", false); in my mozilla.cfg file with no success.

    ''philipp [[#answer-665520|said]]''
    <blockquote>
    hi, does this work?
    defaultPref("browser.search.defaultenginename.US", "data:text/plain,browser.search.defaultenginename.US=Google");
    </blockquote>
    Unfortunately, no it does not.

  • How to sign a powershell script to be used for distribution

    Hi,
    I am new to powershell so if I'm missing out on any detail, please let me know.
    We have some powershell scripts we send over to the clients to execute. Their powershell enviroment has execution policy set to 'remote signed'
    Now I have read multiple blogs for how to sign the powershell script to be used at different execution levels, but my understanding is signing is for my environment only.
    http://www.hanselman.com/blog/SigningPowerShellScripts.aspx
    http://blogs.technet.com/b/heyscriptingguy/archive/2010/06/17/hey-scripting-guy-how-can-i-sign-windows-powershell-scripts-with-an-enterprise-windows-pki-part-2-of-2.aspx
    I'm probably missing out on something obvious and I'll appreciate if someone can explain me how to sign my script so that client can use it in their environment with any execution level set.
    Thanks in advance!

    Here's a bit more information on the subject:
    http://technet.microsoft.com/en-us/library/hh847874.aspx
    http://msdn.microsoft.com/en-us/library/ms537361.aspx
    You can get code signing certificates from the major vendors.
    Don't retire TechNet! -
    (Don't give up yet - 13,085+ strong and growing)

  • How to determine installed version of EMET via script?

    Hi all,
    I was not able to find a easy way to determine installed verison of EMET via script. If you can guide me in the right direction, this would help a lot.
    Many thanks
    Sam

    This is probably not the right forum for scripting questions and you didn't specify which script you (want to) use... Below you can find some examples...
    If you use VBscript you could use WMI and query the class Win32_Product:
    strComputer = "."
    Set objWMIService = GetObject("winmgmts:" _
    & "{impersonationLevel=impersonate}!\\" _
    & strComputer & "\root\cimv2")
    Set colSoftware = objWMIService.ExecQuery _
    ("Select * from Win32_Product where Name like '%EMET%'")
    For Each objSoftware in colSoftware
    Wscript.Echo "Name: " & objSoftware.Name
    Wscript.Echo "Version: " & objSoftware.Version
    Next
    This method is not advisable because the class isn't optimized for queries and therefore the query takes a long time!
    You can also use the Windows Installer object:
    Option Explicit
    ' Connect to Windows Installer object
    Dim installer
    Set installer = Wscript.CreateObject("WindowsInstaller.Installer")
    Dim product, products
    Set products = installer.Products
    For Each product In products
    if instr(1,installer.ProductInfo(product, "InstalledProductName"), "EMET", vbTextCompare) > 0 AND instr(1,installer.ProductInfo(product, "Publisher"), "Microsoft", vbTextCompare) > 0 then
    Wscript.Echo installer.ProductInfo(product, "InstalledProductName")
    Wscript.Echo installer.ProductInfo(product, "VersionString")
    End If
    Next
    Set products = Nothing
    Set installer = Nothing
    Wscript.Quit 0
    This method enumerates all the products but be aware that you should also check the installstate because the installstate of a product also can be advertised.
    You can also use powershell to enumerate the uninstall registry keys but you have take into account that the results may be different on a 64-bit Windows and the bitness of the powershell proces:
    gci "hklm:\software\microsoft\windows\currentversion\uninstall" | foreach { gp $_.PSPath } | select DisplayVersion,DisplayName | where { $_.DisplayName -match "^EMET*" }
    You can also install and use the
    Windows Installer PowerShell Module and use this command:
    get-msiproductinfo | where { $_.Name -like '*EMET*' } | select ProductName,ProductVersion  | format-list
    On the internet you can find a lot of information about your question. For instance I found these pages:
    http://blogs.technet.com/b/heyscriptingguy/archive/2013/11/15/use-powershell-to-find-installed-software.aspx
    http://blogs.technet.com/b/alexshev/archive/2008/06/30/from-msi-to-wix-part-17-windows-installer-automation-interface-part-2.aspx
    W. Spu

  • How do I enable a Java plug-in via script that was just added to the blocklist?

    I need to enable Java 6u29 that was just added to the blocklist via script because there are several thousand end-nodes involved. Also, I am constrained to Firefox 3.6 due application compatibility issues.

    Probably the only or easiest way to remove or disable the blocklist of older Java versions would be to disable blocklisting by locking the extensions.blocklist.enabled to false via a mozilla.cfg file.<br />
    You are already running a no longer supported Firefox 3.6.x version that won't receive updates.
    You can use a mozilla.cfg file in the Firefox program folder to lock prefs or specify new (default) values.
    Place a file local-settings.js in the defaults\pref folder where you also find the file channel-prefs.js to specify using mozilla.cfg.
    pref("general.config.filename", "mozilla.cfg");
    pref("general.config.obscure_value", 0); // use this to disable the byte-shift
    See:
    *http://kb.mozillazine.org/Locking_preferences
    You can use these functions in mozilla.cfg:
    defaultPref(); // set new default value
    pref(); // set pref, but allow changes in current session
    lockPref(); // lock pref, disallow changes
    lockPref("extensions.blocklist.enabled", false);
    *http://kb.mozillazine.org/extensions.blocklist.enabled

  • How to get name of the slicer via script

    Hi Gurus,
    I was wondering if we could get the name of the slicer added in IR Query section, via script ??
    That is, I have a bqy connecting to Essbase OLAP.
    Now I am adding a slicer in OLAP Section via script.
    For Ex : ActiveDocument.Sections["Query2"].Slicers.Add('Market.Gen3,Market' , 'Market.LA')
    Now,for some reason, I wanted to retrieve the name of the slicer I added and assign it to a variable. Is this possible ?? I couldn't see any option for this. Please help me out if any one has done this before ?
    Thank You,
    Aji

    Sethil,
    Use your date(let us say Date1) instead of sy-datum.
    CALL FUNCTION 'MONTH_NAMES_GET'
    EXPORTING
    LANGUAGE = SY-LANGU
    IMPORTING
    RETURN_CODE =
    TABLES
    MONTH_NAMES = itab_month
    EXCEPTIONS
    MONTH_NAMES_NOT_FOUND = 1
    OTHERS = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    READ TABLE itab_month
    WITH KEY MNR = date1+4(2).
    itab_month-LTX will contain the value you are looking for
    Good luck
    Raghava

  • How to modify default value of Login Shell attribute via script

    Hi all,
    I'm configuring the "UNIX Attributes" tab here in Active Directory Users and Computers. I've noticed that on the Login Shell option it has a default value: /bin/sh. So I had manually changed it to: /bin/bash.  I just change this value one
    bu one manually.  Now, I want to change this value for all users via script. Could you please help me to receive this goal?
    Thank you in advance.

    Use Get-AdUser / Set-AdObject
    Get-AdUser -Filter * | Set-AdObject -Replace @{unixhomedirectory='/bin/sh','bin/bash'} -WhatIf
    ¯\_(ツ)_/¯

  • How to set layer color property via script?

    I'm looking for a way to set a layer's UI color property via script (see attached). Any help would be greatly appreciated!

    jrapczak2 wrote:
    Uhm.. wow. That's crazy complicated
    It is even more complicated to work with multi-selected layers.
    if( app.documents.length > 0 && versionCheck()  ){
         app.activeDocument.suspendHistory("Set Layer's Color", 'changeLayersColor()');
    function versionCheck()  { return app.version.match(/1[1|2]./) >= 11; };
    function changeLayersColor(){
         function setActiveLayerColor( color ) {
              var desc = new ActionDescriptor();
                   var ref = new ActionReference();
                   ref.putEnumerated( charIDToTypeID('Lyr '), charIDToTypeID('Ordn'), charIDToTypeID('Trgt') );
              desc.putReference( charIDToTypeID('null'), ref );
                   var colorEnumDesc = new ActionDescriptor();
                   colorEnumDesc.putEnumerated( charIDToTypeID('Clr '), charIDToTypeID('Clr '), color );
              desc.putObject( charIDToTypeID('T   '), charIDToTypeID('Lyr '), colorEnumDesc );
              executeAction( charIDToTypeID('setd'), desc, DialogModes.NO );
         function getSelectedLayersIdx(){
                   var selectedLayers = new Array;
                   var ref = new ActionReference();
                   ref.putEnumerated( charIDToTypeID("Dcmn"), charIDToTypeID("Ordn"), charIDToTypeID("Trgt") );
                   var desc = executeActionGet(ref);
                   if( desc.hasKey( stringIDToTypeID( 'targetLayers' ) ) ){
                        desc = desc.getList( stringIDToTypeID( 'targetLayers' ));
                         var c = desc.count
                         var selectedLayers = new Array();
                         for(var i=0;i<c;i++){
                             try{
                                  activeDocument.backgroundLayer;
                                  selectedLayers.push(  desc.getReference( i ).getIndex() );
                             }catch(e){
                                  selectedLayers.push(  desc.getReference( i ).getIndex()+1 );
                    }else{
                        var ref = new ActionReference();
                        ref.putProperty( charIDToTypeID("Prpr") , charIDToTypeID( "ItmI" ));
                        ref.putEnumerated( charIDToTypeID("Lyr "), charIDToTypeID("Ordn"), charIDToTypeID("Trgt") );
                        try{
                             activeDocument.backgroundLayer;
                             selectedLayers.push( executeActionGet(ref).getInteger(charIDToTypeID( "ItmI" ))-1);
                        }catch(e){
                             selectedLayers.push( executeActionGet(ref).getInteger(charIDToTypeID( "ItmI" )));
                   return selectedLayers;
         function makeActiveByIndex( idx, visible ){
              if( idx.constructor != Array ) idx = [ idx ];
              for( var i = 0; i < idx.length; i++ ){
                   var desc = new ActionDescriptor();
                   var ref = new ActionReference();
                   ref.putIndex(charIDToTypeID( "Lyr " ), idx[i] );
                   desc.putReference( charIDToTypeID( "null" ), ref );
                   if( i > 0 ) {
                        var idselectionModifier = stringIDToTypeID( "selectionModifier" );
                        var idselectionModifierType = stringIDToTypeID( "selectionModifierType" );
                        var idaddToSelection = stringIDToTypeID( "addToSelection" );
                        desc.putEnumerated( idselectionModifier, idselectionModifierType, idaddToSelection );
                   desc.putBoolean( charIDToTypeID( "MkVs" ), visible );
                   executeAction( charIDToTypeID( "slct" ), desc, DialogModes.NO );
         var colors = ['None','Red','Orange','Yellow','Green','Blue','Violet','Grey'];
         var colorIDs = [charIDToTypeID('None'),
                                  charIDToTypeID( "Rd  " ),
                                  charIDToTypeID( "Orng" ),
                                  charIDToTypeID( "Ylw " ),
                                  charIDToTypeID( "Grn " ),
                                  charIDToTypeID( "Bl  " ),
                                  charIDToTypeID( "Vlt " ),
                                  charIDToTypeID( "Gry " )];
         var dlg = new Window( 'dialog', 'Change Layer Color' );
         dlg.ddColors= dlg.add("dropdownlist", undefined,  colors);
         dlg.ddColors.preferredSize.width = 100;
         dlg.ddColors.items[0].selected = true;
         dlg.ok = dlg.add('button',undefined,'Ok');
         dlg.cancel = dlg.add('button',undefined,'Cancel');
         var results = dlg.show();
         if( results == 1 ){
              var selectedLayers =  getSelectedLayersIdx();
              for( var l=0;l<selectedLayers.length;l++ ){
                   makeActiveByIndex( selectedLayers[l], false );
                   setActiveLayerColor( colorIDs[dlg.ddColors.selection.index] );
              makeActiveByIndex( selectedLayers,false );

Maybe you are looking for