Jump to content

Search the Community

Showing results for tags 'Input field'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 1 result

  1. I am attempting to add to input fields to this form to accept Cut and Paste of multiple entries, one per line, to parse through the 2 box and then generate the code needed. Currently it works perfect with single entries in each box, but to make it really useful would be to allow for either Cut/Paste or reading a text file to help generate the scripts. Below is the current code I have. the utility uses the the Microsoft Utility NTRights.exe to work. i was unable to attach the file so i apologize. #region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Icon=....ICONSCNFNOT.ICO #AutoIt3Wrapper_Res_Description=Created to Manually add Local Security rights to servers #AutoIt3Wrapper_Res_Fileversion=1.0.0.0 #AutoIt3Wrapper_Res_LegalCopyright=Brian Foster - ION Communications #endregion ;**** Directives created by AutoIt3Wrapper_GUI **** #include <buttonconstants.au3> #include <comboconstants.au3> #include <editconstants.au3> #include <guiconstantsex.au3> #include <staticconstants.au3> #include <tabconstants.au3> #include <windowsconstants.au3> #include <constants.au3> ;Add Utility file to script FileInstall("C:ScriptsAddServiceRigthsNTRights.exe", @ScriptDir & "NTRights.exe") #region ### START Koda GUI section ### Form=c:scriptsaddservicerigthsform1.kxf $SecurityRights = GUICreate("Security Rights", 657, 403, 192, 114) GUISetBkColor(0xD4D0C8) $AccountName = GUICtrlCreateInput("AccountName", 16, 72, 193, 21) $MachineName = GUICtrlCreateInput("MachineName", 272, 72, 225, 21) $RightsList = GUICtrlCreateTab(16, 104, 473, 233) $TabSheet1 = GUICtrlCreateTabItem("Logon Privileges") $SeBatchLogonRight = GUICtrlCreateCheckbox("Log on as a batch job", 32, 144, 153, 17) $SeInteractiveLogonRight = GUICtrlCreateCheckbox("Log on locally", 32, 200, 129, 17) $SeDenyInteractiveLogonRight = GUICtrlCreateCheckbox("Deny local logon", 32, 224, 121, 17) $SeServiceLogonRight = GUICtrlCreateCheckbox("Logon as a service ", 32, 264, 129, 17) $SeDenyServiceLogonRight = GUICtrlCreateCheckbox("Deny logon as a service", 32, 288, 145, 17) $SeNetworkLogonRight = GUICtrlCreateCheckbox("Access this Computer from the Network", 208, 168, 217, 17) $SeDenyNetworkLogonRight = GUICtrlCreateCheckbox("Deny Access to this computer from the network", 208, 192, 265, 17) $SeRemoteInteractiveLogonRight = GUICtrlCreateCheckbox("Allow logon through Terminal Services", 208, 264, 241, 17) $SeDenyRemoteInteractiveLogonRight = GUICtrlCreateCheckbox("Deny logon through Terminal Services", 208, 288, 217, 17) $Label1 = GUICtrlCreateLabel("The Following are not supported on Windows 2000", 208, 240, 245, 17) GUICtrlSetFont(-1, 8, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x800000) $SeDenyBatchLogonRight = GUICtrlCreateCheckbox("Deny logon as a batch job", 32, 168, 129, 17) $SeDebugPrivilege = GUICtrlCreateCheckbox("Debug programs", 208, 145, 129, 17) $TabSheet2 = GUICtrlCreateTabItem("SysAdmin Privileges") $SeAuditPrivilege = GUICtrlCreateCheckbox("Generate security audits ", 32, 144, 185, 17) $SeSecurityPrivilege = GUICtrlCreateCheckbox("Manage auditing and security log", 32, 170, 185, 17) $SeBackupPrivilege = GUICtrlCreateCheckbox("Backup files and directories", 32, 194, 185, 17) $SeMachineAccountPrivilege = GUICtrlCreateCheckbox("Add workstations to the domain", 32, 218, 185, 17) $SeShutdownPrivilege = GUICtrlCreateCheckbox("Shut down the system ", 32, 242, 185, 17) $SeRemoteShutdownPrivilege = GUICtrlCreateCheckbox("Force shutdown from a remote system", 32, 266, 209, 17) $SeCreatePagefilePrivilege = GUICtrlCreateCheckbox("Create a pagefile", 32, 290, 185, 17) $SeIncreaseQuotaPrivilege = GUICtrlCreateCheckbox("Increase quotas", 257, 146, 185, 17) $SeRestorePrivilege = GUICtrlCreateCheckbox("Restore files and directories", 257, 172, 185, 17) $SeSystemTimePrivilege = GUICtrlCreateCheckbox("Change the system time", 257, 196, 185, 17) $SeManageVolumePrivilege = GUICtrlCreateCheckbox("Manage the files on a volume (XP Only)", 257, 220, 217, 17) $SeTakeOwnershipPrivilege = GUICtrlCreateCheckbox("Take ownership of files/objects", 257, 244, 185, 17) $SeUndockPrivilege = GUICtrlCreateCheckbox("Remove computer from docking station", 257, 268, 225, 17) $SeEnableDelegationPrivilege = GUICtrlCreateCheckbox("Enable computer/user accounts to be trusted for delegation", 257, 290, 185, 33, BitOR($GUI_SS_DEFAULT_CHECKBOX, $BS_MULTILINE)) GUICtrlSetResizing(-1, $GUI_DOCKAUTO + $GUI_DOCKTOP + $GUI_DOCKBOTTOM + $GUI_DOCKHEIGHT) $TabSheet3 = GUICtrlCreateTabItem("Service Privileges") $SeCreatePermanentPrivilege = GUICtrlCreateCheckbox("Create permanent shared objects", 32, 152, 193, 17) $SeCreateTokenPrivilege = GUICtrlCreateCheckbox("Create a token object", 32, 176, 209, 17) $SeAssignPrimaryTokenPrivilege = GUICtrlCreateCheckbox("Replace a process-level token", 32, 200, 177, 17) $SeImpersonatePrivilege = GUICtrlCreateCheckbox("Impersonate a client after authentication", 32, 224, 217, 17) $SeIncreaseBasePriorityPrivilege = GUICtrlCreateCheckbox("Increase scheduling priority", 32, 248, 225, 17) $SeTcbPrivilege = GUICtrlCreateCheckbox("Act as part of the operating system ", 272, 152, 201, 17) $SeProfileSingleProcessPrivilege = GUICtrlCreateCheckbox("Profile a single process", 272, 176, 185, 17) $SeLoadDriverPrivilege = GUICtrlCreateCheckbox("Load and unload device drivers", 272, 200, 201, 17) $SeLockMemoryPrivilege = GUICtrlCreateCheckbox("Lock pages in memory", 272, 224, 201, 17) $SeCreateGlobalPrivilege = GUICtrlCreateCheckbox("Create global objects", 272, 248, 193, 17) $TabSheet4 = GUICtrlCreateTabItem("Misc. Privileges") $SeChangeNotifyPrivilege = GUICtrlCreateCheckbox("Bypass traverse checking", 32, 160, 161, 17) $SeSyncAgentPrivilege = GUICtrlCreateCheckbox("Synch directory service data", 32, 192, 161, 17) $SeSystemEnvironmentPrivilege = GUICtrlCreateCheckbox("Edit firmware environment values", 32, 224, 225, 17) $SeSystemProfilePrivilege = GUICtrlCreateCheckbox("Profile system performance", 32, 256, 177, 17) GUICtrlCreateTabItem("") $RUN = GUICtrlCreateButton("RUN File", 24, 352, 81, 25) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0x008000) $EXIT = GUICtrlCreateButton("EXIT", 392, 352, 81, 25) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0x800000) $Label2 = GUICtrlCreateLabel("Enter Account name to grant rights to:", 16, 40, 221, 17) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") $Label3 = GUICtrlCreateLabel("Domainusername(group) ", 16, 56, 150, 17) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") $Label4 = GUICtrlCreateLabel("Enter remote Machine Name or LocalHost", 272, 56, 240, 17) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") $Generate = GUICtrlCreateButton("Generate File", 168, 352, 121, 25) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0x000080) $Privileges = GUICtrlCreateCombo("GRANT Privilege", 496, 176, 129, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) GUICtrlSetData(-1, "REMOVE Privilege") GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) GUICtrlSetBkColor(-1, 0xECE9D8) $Label5 = GUICtrlCreateLabel("Select to ADD/ REMOVE", 496, 152, 147, 17) GUICtrlSetFont(-1, 6, 800, 4, "MS Sans Serif") GUISetState(@SW_SHOW) #endregion ### END Koda GUI section ### Dim $File While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE FileDelete(@ScriptDir & "NTRights.exe") Exit Case $RUN _CREATEFile() $Line = '"' & $File & '" >"' & $File & ".log" & '"' RunWait($Line, "", @SW_HIDE) FileDelete($File) MsgBox("", "Log File has been saved as: ", $File & ".log") Case $EXIT FileDelete(@ScriptDir & "NTRights.exe") Exit Case $Generate _CREATEFile() MsgBox("", "File Save Location", "Your File has been saved to: " & @CRLF & @CRLF & $File) EndSwitch WEnd Func _CREATEFile() Dim $Priv $User = GUICtrlRead($AccountName) $CPU = GUICtrlRead($MachineName) If $User = "AccountName" Then MsgBox("", "Change Account Name", "Please Change the Account Name before continuing") If $CPU = "MachineName" Then MsgBox("", "Change Machine Name", "Please change the Machine Name before continuing") If GUICtrlRead($Privileges) = "GRANT Privilege" Then $Priv = "+r" Else $Priv = "-r" EndIf $File = @MyDocumentsDir & "" & $CPU & "_" & @MSEC & ".CMD" $Writefile = FileOpen($File, 1) If GUICtrlRead($SeBatchLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeBatchLogonRight") If GUICtrlRead($SeInteractiveLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeInteractiveLogonRight") If GUICtrlRead($SeDenyInteractiveLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeDenyInteractiveLogonRight") If GUICtrlRead($SeServiceLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeServiceLogonRight") If GUICtrlRead($SeDenyServiceLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeDenyServiceLogonRight") If GUICtrlRead($SeNetworkLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeNetworkLogonRight") If GUICtrlRead($SeDenyNetworkLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeDenyNetworkLogonRight") If GUICtrlRead($SeRemoteInteractiveLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeRemoteInteractiveLogonRight") If GUICtrlRead($SeDenyRemoteInteractiveLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeDenyRemoteInteractiveLogonRight") If GUICtrlRead($SeDenyBatchLogonRight) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeDenyBatchLogonRight") If GUICtrlRead($SeDebugPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeDebugPrivilege") If GUICtrlRead($SeAuditPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeAuditPrivilege") If GUICtrlRead($SeSecurityPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeSecurityPrivilege") If GUICtrlRead($SeBackupPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeBackupPrivilege") If GUICtrlRead($SeMachineAccountPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeMachineAccountPrivilege") If GUICtrlRead($SeShutdownPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeShutdownPrivilege") If GUICtrlRead($SeRemoteShutdownPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeRemoteShutdownPrivilege") If GUICtrlRead($SeCreatePagefilePrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeCreatePagefilePrivilege") If GUICtrlRead($SeIncreaseQuotaPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeIncreaseQuotaPrivilege") If GUICtrlRead($SeRestorePrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeRestorePrivilege") If GUICtrlRead($SeSystemTimePrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeSystemTimePrivilege") If GUICtrlRead($SeManageVolumePrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeManageVolumePrivilege") If GUICtrlRead($SeTakeOwnershipPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeTakeOwnershipPrivilege") If GUICtrlRead($SeUndockPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeUndockPrivilege") If GUICtrlRead($SeEnableDelegationPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeEnableDelegationPrivilege") If GUICtrlRead($SeCreatePermanentPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeCreatePermanentPrivilege") If GUICtrlRead($SeCreateTokenPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeCreateTokenPrivilege") If GUICtrlRead($SeAssignPrimaryTokenPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeAssignPrimaryTokenPrivilege") If GUICtrlRead($SeImpersonatePrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeImpersonatePrivilege") If GUICtrlRead($SeIncreaseBasePriorityPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeIncreaseBasePriorityPrivilege") If GUICtrlRead($SeTcbPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeTcbPrivilege") If GUICtrlRead($SeProfileSingleProcessPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeProfileSingleProcessPrivilege") If GUICtrlRead($SeLoadDriverPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeLoadDriverPrivilege") If GUICtrlRead($SeLockMemoryPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeLockMemoryPrivilege") If GUICtrlRead($SeCreateGlobalPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeCreateGlobalPrivilege") If GUICtrlRead($SeChangeNotifyPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeChangeNotifyPrivilege") If GUICtrlRead($SeSyncAgentPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeSyncAgentPrivilege") If GUICtrlRead($SeSystemEnvironmentPrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeSystemEnvironmentPrivilege") If GUICtrlRead($SeSystemProfilePrivilege) = 1 Then FileWriteLine($Writefile, "NTRights -u " & '"' & $User & '"' & " -m " & $CPU & " " & $Priv & " " & "SeSystemProfilePrivilege") FileClose($Writefile) Return ($File) EndFunc ;==>_CREATEFile
×
×
  • Create New...