PDA

Просмотр полной версии : Security



Самогон
22.11.2011, 20:47
После не помню какого патча W2K3R2SP2 ломает настройки security manager и закрывает уделенный доступ к Remote Management
Лечится вот так:
Set SCM remote access rights


sc sdset scmanager D:(A;;CCLCRPRC;;;AU)(A;;CCLCRPWPRC;;;SY)(A;;KA;;;BA)S:(AU;FA;KA;;;WD)(AU;OIIOFA;GA;;;WD)

Божья Искра
24.11.2011, 19:29
А как пропатчить KDE под FreeBSD????

Президент Украины дал однозначный ответ: «Шановні друзі, пропатчити можуть допомогти програмісти Секретаріату Президента у різних операційних системах. Другий варіант — радив би користуватися новим программним забезпеченням і не морочити собі голову».

танкист
24.11.2011, 19:43
Ну не серьёзно, ...
темы-то полезные, я так! думаю.

V_V_V
24.11.2011, 20:02
А как пропатчить KDE под FreeBSD????
cd /usr/ports && make index; pkgdb -F
cd /usr/ports/x11/xorg && make all install && make clean
cd /usr/ports/x11/kde3/
make && make install && make clean;
portsnap fetch
portsnap extract
portsnap fetch update
xorgcfg
cp ~/xorg.conf.new /usr/X11R6/etc/X11/xorg.conf
touch ~/.xinitrc && echo -ne “exec startkde” > ~/.xinitrc
reboot
startx(С)
:biggrin:

Самогон
24.11.2011, 20:32
Вот так для всех портов установленных

# portsnap fetch update
# pkg_version -l '<'
# portmaster -Da

Самогон
16.12.2011, 03:10
Задача: добавить доменную группу в LocalAdministrators группу на каждом сервере из списка в файле servers.txt (один сервер на строку)
Запускать лучше с помощью cscript что бы не щелкать ОК на каждое сообшение.

Вот слепил из того что было


'Add2LocalAdmin.vbs
Dim objFSO, strTextFile, strData, strLine, arrLines, Domain, GroupName, ComputerName
CONST ForReading = 1
Domain = "Pre2000domainname"
GroupName = "GROUP-YOU-NEED-TO-ADD"
'name of the text file with list of servers
strTextFile = "servers.txt"

'Create a File System Object
Set objFSO = CreateObject("Scripting.FileSystemObject")

'Open the text file - strData now contains the whole file
strData = objFSO.OpenTextFile(strTextFile,ForReading).ReadAll

'Split the text file into lines
arrLines = Split(strData,vbCrLf)

'Step through the lines
For Each strLine in arrLines
'wscript.echo strLine
ComputerName = strLine
'aAdd the group to the local administrators group
Wscript.echo vbCrLf & "Adding " & Domain & "\" & GroupName & _
" to the local administrators group on " & ComputerName
Select Case AddGroupToLocalAdmins(ComputerName,Domain,GroupName)
Case 0
wscript.echo " Succes"
Case 1
wscript.echo " Failed - unable to add the account to the local administrators group"
Case 2
wscript.echo " Already a member"
Case 3
wscript.echo " Failed - Unable to connect to the computer"
End Select

Next
'Cleanup
Set objFSO = Nothing



'#############################
'Function AddGroupToLocalAdmins

'Variables
'ComputerName
'Domain of Group being added
'GroupName (User account can be used as well)

'Returns
'0 if Group is added successfully to the local Admin group
'1 if function was unable to add the Group to the local Admin group
'2 if Group is already a member of the local Admin group
'3 if the function was unable to connect to the specified Computer

Function AddGroupToLocalAdmins(ComputerName,Domain,GroupName)

On Error Resume Next

'Create an group object referencing the local Administrators group on the
'Computer
Set objLocalGroup = GetObject("WinNT://" & ComputerName & "/Administrators, group")
If Err.Number = 0 Then

'Check to see if the Group already exists in the local Admin group
For each Group in objLocalGroup.Members
If Instr(ucase(Group.ADSPath),ucase(Domain & "/" & GroupName)) <> 0 Then
AlreadyExists = True
End If
Next

'Add the specified group to the local Administrators group if it doesn't already
'exist
If AlreadyExists = False Then
objLocalGroup.Add("WinNT://" & Domain & "/" & GroupName)

If Err.Number = 0 Then
AddGroupToLocalAdmins = 0
Else
AddGroupToLocalAdmins = 1
Err.Clear
End If

Else
AddGroupToLocalAdmins = 2
End If

Else
AddGroupToLocalAdmins =3
Err.Clear
End If

End Function

'#############################