Showing posts with label Client security. Show all posts
Showing posts with label Client security. Show all posts

Friday, August 26, 2011

эффективность против порядка

Вы отвечаете за защиту периферии в компании. Написали множество регламентов, просматриваете журналы, проводите занятия и тп.

В компании стоит... ну скажем 1000 компьютеров, мышками которых возит 1000 сотрудников. Для ремонта мышек и их подключения, в компании создана служба технической поддержки из нескольких сотрудников.

У сотрудника возникают проблемы с мышкой во момент Х.

Так как мышки ломаются не чаще раза в 2 года, сотрудник втечение Х1 единиц времени думает, как решить проблему, стучит мышкой по столу, смотрит в красный глаз, курит, снова стучит и наконец, в соответствии с регламентом, звонит на телефон 22232232 (читать с выражением) и сообщает о сути проблемы.

Телефонная сотрудница регистрирует заявку в "электронной системе электронных заявок" которая электронно, по электронной почте сообщает сотрудникам технической поддержки о возникновении проблемы.

Через время Х2 сотрудник технической поддержки обращает внимание на сообщение и откладывает его в пачку сообщений, которые предполагают поход в одно крыло здания.

Спустя Х3 единиц времени он выходит в направлении неисправной мышки и спустя Х4 единиц, он ситуацию исправляет.

Итого, на устранение неисправности ушло Х1+Х2+Х3+Х4 единиц времени. В реальной жизни это время составляет от пары часов до пары дней. Все это время сотрудник сидит и полукоматозном состоянии изучает символы на клавиатуре, сообщая руководству о невозможности исполнения служебных обязанностей.

И вот находится человек, который умеет ремонтировать мышки! Но так как он двигает мышь удивительно быстро и эффективно, руководство не может использовать его как техническую поддержку, получая большую отдачу от него как от двигателя мыши.

Наступает момент Х, мышь у этого человека ломается! Или он регулярно находит способы сделать мышь лучше и быстрее! Или еще хуже, он делает заявки и получает форсированные мыши 1го, затем 2го и, наконец ,7го поколения с азотным ускорителем.

В первый раз он звонит на волшебный номер и ждет в течение Х2+Х3+Х4 человека, которому компания доверила техническое обслуживание мышей. Но начальство нервничает, ведь оно привыкло видеть отдачу от сотрудника.

Во второй раз и третий недовольство руководства растет....

На четвертый раз наш волшебный сотрудник рассуждая "ведь моя Компания платит мне заработную плату и я не в праве сидеть, сложа руки, в то время, когда от меня ждут новых и четких движений мышью" принимает решение "я могу и я должен сам исправить проблемы мыши моего компьютера".

О, ужас! Он не звонит в техническую поддержку, он не ловит системотехника в коридоре за руку! Он.... Как трудно сдержать гнев! Он нарушает стандарт утвержденный руководителем компании! Он, он... Он сам переподключил мышь! Коллеги в шоке, но они понимают - все это во благо компании!

А радары службы безопасности не зря потребляют электроны один за другим. Они сигнализируют красными лампами и зуммерами о нарушении, маркируя нарушителя несмываемой краской!

И вот комиссия из 3-х сотрудников сметая все на своем пути мчится к месту проступка. Нарушение будет задокументировано, нарушитель брошен в казематы, руководство уведомлено о нарушении и высокой степени эффективности новых красных ламп приобретенных взамен старых зеленых.

Вроде все хорошо:

  1. Нарушитель пойман и наказан
  2. Лампы сработали
  3. Системотехники не будут мучаться с нестандартными мышами и их труд по замене стандартных девайсов будет проще и дешевле
  4. Служба безопасности получает медали и премии
  5. Руководство спит спокойно, зная, что компания в теплых и сильных руках службы безопасности.
  6. Выпущена молния, в которой описана темная дорога нарушителя, а так же условия его нынешнего содержания.

Но откуда-то появляется кисловатый привкус:

  1. Средняя эффективность использования мышей упала
  2. Сотрудники стараются не отклоняться от утвержденных траекторий движения
  3. Сломанных мышей начинают бояться и на всякий случай отправляют в неоплачиваемый отпуск их пользователей.

Thursday, March 19, 2009

Контроль сменных носителей

Контроль сменных носителей - тема нынче весьма популярная и обсуждаемая.
Но бесплатных средств, работающих под ОС Windows и более менее управляемых в небольшой сети, найти не удалось.
Платные средства дешевле 500 рублей за рабочее место не существуют, что в нынешних условиях непосильные деньги для многих компаний. Посему на коленке был сделан небольшой скрипт, который каждый час запускается на АРМ пользователей. Запуск и его контроль осуществляется средствами Microsoft SMS (который уже есть в наличии).
Данный скрипт позволяет довольно успешно контролировать работу сменных носителей в небольшом домене, содержащем чуть более 150 рабочих станций и серверов.

Скрипт может запускаться так же средствами групповой политики Active Directory, но механизм этот не столь гибок, сколь хотелось бы.

Небольшие комментарии по коду:

  • первый цикл определяет имя пользователя вошедшего в систему
  • второй цикл определяет входит ли пользователь в доменную группу "UsbFullControl", назначение группы понятно из её названия
  • третий цикл делает то же для группы "UsbReadOnly"
  • если пользователь не входит ни в одну из групп, значит ему не повезло - выключается возможность работы со всеми сменными устройствами
  • иначе делаются настройки облегчающие работу с флешками и разрешающие работу с дискетами и оптическими дисками
  • Для работы скрипта нужны административные права, либо права SYSTEM, то есть он не эффективен в сети, где большое число пользователей имеет права локальных администраторов.
Безусловно, групп может быть больше, привязку можно делать к имени компьютера и все списки спрятать внутри скрипта. Тут уж все зависит от фантазии внедренца.

Источники идеи уже не найду. Среди них результаты поиска по словам "usb control security", а так же материалы с сайта Microsoft.

---------------

@ECHO OFF

:: delims is a TAB followed by a space
FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v DefaultUserName') DO SET LastLogon=%%B

For /F "tokens=1" %%A in ('net user %LastLogon% /domain ^| find /i "UsbFullControl"') Do Set Group=%%A
IF NOT "%Group%"=="" GOTO UsbFullControl

For /F "tokens=1" %%A in ('net user %LastLogon% /domain ^| find /i "UsbReadOnly"') Do Set Group=%%A
IF NOT "%Group%"=="" GOTO UsbReadOnly

:UsbDenyAll
move %SystemRoot%\Inf\Usbstor.pnf %SystemRoot%\Inf\Usbstor.pnf.old
move %SystemRoot%\Inf\Usbstor.inf %SystemRoot%\Inf\Usbstor.inf.old

> "%Temp%.\usb.reg" echo REGEDIT4
>>"%Temp%.\usb.reg" echo.
>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Flpydisk]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000004

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Sfloppy]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000004

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Cdrom]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000004

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UsbStor]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000004
>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\StorageDevicePolicies]
>>"%Temp%.\usb.reg" echo "WriteProtect"=dword:00000001
>>"%Temp%.\usb.reg" echo.

start /wait regedit /s "%Temp%.\usb.reg"

del "%Temp%.\usb.reg"

GOTO End

:UsbFullControl
move %SystemRoot%\Inf\Usbstor.pnf.old %SystemRoot%\Inf\Usbstor.pnf
move %SystemRoot%\Inf\Usbstor.inf.old %SystemRoot%\Inf\Usbstor.inf

> "%Temp%.\usb.reg" echo REGEDIT4
>>"%Temp%.\usb.reg" echo.
>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Flpydisk]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Sfloppy]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Cdrom]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UsbStor]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003
>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\StorageDevicePolicies]
>>"%Temp%.\usb.reg" echo "WriteProtect"=dword:00000000
>>"%Temp%.\usb.reg" echo.

start /wait regedit /s "%Temp%.\usb.reg"

del "%Temp%.\usb.reg"
GOTO End

:UsbReadOnly
move %SystemRoot%\Inf\Usbstor.pnf.old %SystemRoot%\Inf\Usbstor.pnf
move %SystemRoot%\Inf\Usbstor.inf.old %SystemRoot%\Inf\Usbstor.inf

> "%Temp%.\usb.reg" echo REGEDIT4
>>"%Temp%.\usb.reg" echo.
>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Flpydisk]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Sfloppy]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Cdrom]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003

>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UsbStor]
>>"%Temp%.\usb.reg" echo "Start"=dword:00000003
>>"%Temp%.\usb.reg" echo [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\StorageDevicePolicies]
>>"%Temp%.\usb.reg" echo "WriteProtect"=dword:00000001
>>"%Temp%.\usb.reg" echo.

start /wait regedit /s "%Temp%.\usb.reg"

del "%Temp%.\usb.reg"

GOTO End


:End

Wednesday, January 16, 2008

New Banking Trojan

This is really awesome. Latest piece of technology from trojan makers. Please note the ability to defeat best practice of "authenticate transactions, not just sessions". This once again underlines importance of endpoint security - you cannot be safe if your computer is compromised.

http://www.symantec.com/enterprise/security_response/weblog/2008/01/banking_in_silence.html

The ability of this Trojan to perform man-in-the-middle attacks on valid transactions is what is most worrying. The Trojan can intercept transactions that require two-factor authentication. It can then silently change the user-entered destination bank account details to the attacker's account details instead. Of course the Trojan ensures that the user does not notice this change by presenting the user with the details they expect to see, while all the time sending the bank the attacker's details instead. Since the user doesn’t notice anything wrong with the transaction, they will enter the second authentication password, in effect handing over their money to the attackers. The Trojan intercepts all of this traffic before it is encrypted, so even if the transaction takes place over SSL the attack is still valid. Unfortunately, we were unable to reproduce exactly such a transaction in the lab. However, through analysis of the Trojan's code it can be seen that this feature is available to the attackers.

Tuesday, January 15, 2008

SANS: Top Ten Cyber Security Menaces for 2008

SANS has posted Top Ten Cyber Security Menaces for 2008.
To my mind this can be a good argument against low attention to securing employee Internet access and mobile devices.

Friday, November 9, 2007

Five Simple Rules of Client Security Proved in Practice

Several days ago I helped friend of mine install Windows XP Professional on his home computer. I made default installation of XP SP2 and created two users with default options – these accounts were created with administrator rights.

After that he made a contract with local Internet provider and plugged into the Internet. My friend had admired by the Internet up to depth of his soul, – he was very happy to be able to visit internet sites at home.

But two days latter he phoned me complaining that his new computer had become very slow and he sees a lot of prompters from Kaspersky AV telling him that his computer is infected with malware. I should mention that he has 30-days evaluation version of Kaspersky with old virus base.

I downloaded latest CureIT and went to my friend’s place. But when I came I found that all my attempts to log on to Windows immediately ended with logging off. I found a number of materials about malware that change HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon subkey and decided that problem was in that. Then I made a BartPE CD and loaded from it. I found that C:\Windows\System32\Userinit.exe simply absent. I copied it from I386 directory of XP installation CD. After that I decided to look at HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run. I loaded offline registry and I found two suspicious programs that start from C:\Windows\system32 and C:\Windows\Temp. Unfortunately I don’t remember exact names but I have been assured, that they can be deleted safely. Finally, I started CureIT against whole C:. Remember, it was three days old XP SP2 installation, so C: didn’t contain much data. It ended with more that 50 different malware found! Mainly they were Trojans. I know that some malware block AV updates by editing C:\WINDOWS\system32\drivers\etc\hosts file so I decided to check it too. Well, I hadn’t mistaken – I commented 35 rows of well-known update services including Microsoft Windows update, Symantec Live update, etc.

After that long process of getting rid of viruses, assuming that my friend will not buy antivirus so computer will not be protected with AV and also he will not update Windows because it takes too much Internet traffic that costs money I wrote for him 5 simple rules that should help him to stay somehow protected against Internet threats. Here they are.

  1. Do not surf the Internet with admin rights. Very simple – if you catch something, it won’t destroy your system, just your profile.
  2. Do not use IE. Since you don’t update your Windows, IE is not updated as well. Use Firefox – it’s free and seems more secure.
  3. If browser asks you something, read this carefully and only after this make your decision. If you feel lazy and don’t want to read – answer ‘No’.
  4. Try to avoid unknown sites. I know that it’s difficult, – that’s why I said ‘try’.
  5. Do not install plug-ins. Even if everything is OK with your browser core you still can be successfully attacked through plug-is. See, for example, page 7 here.

Additionally, it’s good idea to download CureIT and run test periodically, for example, once a week.

Inside myself I was very frightened because I don’t have AV on my home computer, my XP has only SP2 and no other patches and my wife like the Internet very much. The only defense I have – five above rules.

When I came home I ran CureIT against C:. I was very happy with result – ‘No viruses found’. I think it does really prove that 5 rules are working. Don’t misunderstand me, I don’t assert that we don’t need to use AV and install patches, no, but these rules are good trade-off.

Monday, September 10, 2007

Browser security

Recently I mentioned here (unfortunately available only in Russian) that number of discovered vulnerabilities does not indicate level of security. It is a rather strange assertion that Windows is more secure than Linux because it has less discovered faults during specified period of time than Linux.
Here
are facts that show that situation actually is reverse.

On figure 6 we can see charts for Remote code execution vulnerabilities in IE, Firefox and Opera. Using Microsoft's logic IE should be safer... But unfortunately things are not so simple - see figure 7. If the idea is not obvious - read text between these figures:

... As shown in Figure 7, these input URLs that resulted in a 0.5735% of successful compromises of Internet Explorer 6 SP2 did not cause a single successful attack on Firefox 1.5.0 or Opera 8.0.0...

Awareness training: misleading applications.

There are materials (Misleading Applications: faking left, running right, Misleading Applications – What you need to know, KYE: Malicious Web Servers and others) about client security. IT and IT security can fight against such threats on infrastructure level (Web filtering - URL/Content/Category, Anti-virus/-malware/-spyware/-crimeware/etc.) but unfortunately it's not enough because new attack technologies trend to target people as the weakest link in the chain of security countermeasures using social engineering. New kind of such deceiving software - misleading applications - is not exception.

In this short post I outline some very simple rules that can help ordinary people to protect themselves and significantly lower risk of being attacked via Internet clients:

  • Control your patch level and patch level of your antivirus.
  • Do not visit unknown sites.
  • Do not believe unknown sites. If site tries to persuade to install something that will do you good, consult with your IT/IT security. Do not install software from the Internet.
  • Do not open e-mails you don’t expect or from somebody you don’t know. Do not open attachments or click links in such e-mails.
  • Switch off unneeded functionality in client. For example, if you don’t need JavaScript, disable it in your browser.
  • Do not start Internet clients (browser, e-mail client, IM client, etc.) with admin privileges
  • Be paranoid, If you feel suspicion do not hesitate to contact your IT/IT-security.