mirror of
https://github.com/shadow1ng/fscan.git
synced 2025-09-14 05:56:46 +08:00
36 lines
909 B
Go
36 lines
909 B
Go
package ldap
|
||
|
||
import (
|
||
"context"
|
||
|
||
"github.com/shadow1ng/fscan/common"
|
||
"github.com/shadow1ng/fscan/plugins/base"
|
||
)
|
||
|
||
// LDAPExploiter LDAP利用器实现 - 最小化版本,不提供利用功能
|
||
type LDAPExploiter struct {
|
||
*base.BaseExploiter
|
||
}
|
||
|
||
// NewLDAPExploiter 创建LDAP利用器
|
||
func NewLDAPExploiter() *LDAPExploiter {
|
||
exploiter := &LDAPExploiter{
|
||
BaseExploiter: base.NewBaseExploiter("ldap"),
|
||
}
|
||
|
||
// LDAP插件不提供利用功能
|
||
exploiter.setupExploitMethods()
|
||
|
||
return exploiter
|
||
}
|
||
|
||
// setupExploitMethods 设置利用方法
|
||
func (e *LDAPExploiter) setupExploitMethods() {
|
||
// LDAP插件不提供利用功能,仅进行弱密码扫描和匿名访问检测
|
||
}
|
||
|
||
// Exploit 利用接口实现 - 空实现
|
||
func (e *LDAPExploiter) Exploit(ctx context.Context, info *common.HostInfo, creds *base.Credential) (*base.ExploitResult, error) {
|
||
// LDAP插件不提供利用功能
|
||
return nil, nil
|
||
} |