삽질은 나의 힘 | 'Server' 카테고리의 글 목록
삽질은 나의 힘 위치로그  |  태그  |  미디어로그  |  방명록
icon Server 에 해당하는 글4 개
2014.11.03   PAM을 이용한 SMTP-auth 특정사용자 제한(disable SMTP-auth to specified user with PAM)
2012.04.18   process memory 특정 주소 dump
2012.01.12   flush-[major]:[minor] process
2009.12.07   DSN : Return receipt


icon PAM을 이용한 SMTP-auth 특정사용자 제한(disable SMTP-auth to specified user with PAM)
Server/Linux | 2014. 11. 3. 20:50



참고(reference) : http://www.linux-pam.org/Linux-PAM-html/sag-pam_listfile.html





< 메일 수신을 되게 하면서 발신만 안되게 하고 싶은 경우 ( if specified users only want to receive a mail -> block a heavy mail-sender) >





- 파일 수정 (edit  /etc/alternatives/mta-pam)

#%PAM-1.0

auth      required      pam_listfile.so onerr=fail item=user sense=deny file=/etc/smauth_deny_user  // 한줄( one line )

auth       include      system-auth

account    include      system-auth





- 적용할 사용자파일 생성 ( create a file : /etc/smauth_deny_user )


ex) 

user1     // username

user2

user4





- pam 방식 인증여부 확인 ( confirm PAM  auth-mech )


ex)  if use saslauthd,

/usr/sbin/saslauthd -m /var/run/saslauthd -a pam









'Server > Linux' 카테고리의 다른 글

process memory 특정 주소 dump  (0) 2012.04.18
flush-[major]:[minor] process  (0) 2012.01.12
DSN : Return receipt  (0) 2009.12.07

arrow 트랙백 | 댓글



icon process memory 특정 주소 dump
Server/Linux | 2012. 4. 18. 23:42



1. 해당 PID의 메모리 layout 확인
cat /proc/[pid]/maps

2. gdb로 해당 프로세스에 attach
gdb --pid [pid]

3. 위의 1에서 확인한 특정 구간 부분을 파일로 dump
(gdb) dump memory /root/output 0x00621000 0x00622000



원문 :  http://serverfault.com/questions/173999/dump-a-linux-processs-memory-to-file 


arrow 트랙백 | 댓글



icon flush-[major]:[minor] process
Server/Linux | 2012. 1. 12. 22:53

원문 :http://serverfault.com/questions/341123/flush-processes-consume-too-much-of-cpu


오염(수정)된 캐싱 페이지의 writeback [1] 관리와 관련된 프로세스로,

보통의 경우는 CPU를 거의 사용하지 않으며,

대부분의 시간을 디스크에 작업하기를 기다린다. 

만약, 해당 프로세스의 CPU 사용률이 높다면 kernel bug일 가능성이 높다. 



[1] http://publib.boulder.ibm.com/infocenter/eserver/v1r2/topic/diricinfo/fqy0_cwrcache.html

ibm : intercontinental ballistic missile, International Business Machines Corporation

arrow 트랙백 | 댓글



icon DSN : Return receipt
Server/Linux | 2009. 12. 7. 21:20

sendmail 기본설정인 서버기준으로,

Nate
에서 메일을 발송할 때, 메일발송후 수신서버에서 “Return receipt” 메일 메시지가

발송되는 현상관련 로그는 아래와 같다.


( aaaaa가 bbbbb에게 메일을 보내면 정상적으로 메일이 수신되었음을 bbbbb계정이 있는
메일서버에서 aaaaa에게 배달성공메시지를 보낸다.)

Nov 20 17:27:26 www sendmail[6375]: nAK8RQT9006375: from=<aaaaa
@nate.com>, size=1023, class=0, nrcpts=1, msgid=<d564454f517ce4d4c83de9da474e40c9$25d9603d@mail3.nate.com>

TP, daemon=Daemon0, relay=[117.xx.xxx.131]

Nov 20 17:27:26 www sendmail[6376]: nAK8RQT9006375: to=bbbbb@ccc.net, delay=00:00:00, xdelay=00:00:00, mailer=local, pri=31203, dsn=2.0.0, stat=Sent

Nov 20 17:27:26 www sendmail[6376]: nAK8RQT9006375: nAK8RQT9006376: DSN: Return receipt

 

DSN(Delivery Status Notifications) 관련 문서를 찾아본 결과 아래와 같은 부분을 볼 수 있었다.

 

-       Specifically, the DSN SMTP service is used to request that indications of successful delivery or delivery failure (in the DSN format) be returned. Issuance of a DSN upon delivery failure is the default behavior, whereas issuance of a DSN upon successful delivery requires a specific request from the sender.

 

배달 실패시 리턴은 기본적으로 되어있으나,

배달 성공의 경우 리턴은, 메일발송시 보내는 쪽의 특정 요청이 필요한 것으로 보인다.

 

추가하여, 배달성공 리턴메시지를 막기 위해 아래의 방법을 이용할 수 있다.

 

/etc/mail/sendmail.mc 에 아래 구문을 넣고 저장,

================================

define(`confPRIVACY_FLAGS', `noreceipts')dnl

================================

 

# m4 sendmail.mc > sendmail.cf

# killall HUP sendmail

 

번거로우면 간단하게 /etc/mail/sendmail.cf에 아래 구문을 넣고

 

=======================

O PrivacyOptions=noreceipts

=======================

 

# killall HUP sendmail 로 설정파일을 다시 읽어들이시면 바로적용된다.


arrow 트랙백 | 댓글



[PREV] [1] [NEXT]
관리자  |   글쓰기
BLOG main image
분류 전체보기 (27)
Server (4)
Network (3)
Packet Analysis (3)
Security (3)
TroubleShooting (8)
Algorithm (1)
ETC (2)
None (1)
Total :
Today :
Yesterday :
rss
위치로그 : 태그 : 방명록 : 관리자
minSoong-e's Blog is powered by Daum / Designed by plyfly.net