shadow1ng/fscan · error

unexpected_status_code: %d

Error message

unexpected_status_code: %d

What it means

Guard in doRabbitMQAuth: the management API returned a status code outside {200, 401, 403}, e.g. 5xx or 3xx. The code maps to no credential verdict, so the result is marked ErrorTypeUnknown rather than success or auth failure.

Source

Thrown at plugins/services/rabbitmq.go:131

			Success:   true,
			Conn:      &rabbitMQConnWrapper{},
			ErrorType: ErrorTypeUnknown,
			Error:     nil,
		}
	}

	if resp.StatusCode == 401 || resp.StatusCode == 403 {
		return &AuthResult{
			Success:   false,
			ErrorType: ErrorTypeAuth,
			Error:     fmt.Errorf(i18n.GetText("service_auth_failed")+": %d", resp.StatusCode),
		}
	}

	return &AuthResult{
		Success:   false,
		ErrorType: ErrorTypeUnknown,
		Error:     fmt.Errorf(i18n.GetText("unexpected_status_code")+": %d", resp.StatusCode),
	}
}

// rabbitMQConnWrapper RabbitMQ连接包装器
type rabbitMQConnWrapper struct{}

func (w *rabbitMQConnWrapper) Close() error {
	return nil
}

// classifyRabbitMQErrorType RabbitMQ错误分类
func classifyRabbitMQErrorType(err error) ErrorType {
	if err == nil {
		return ErrorTypeUnknown
	}

	rabbitMQAuthErrors := []string{
		"authentication failed",

View on GitHub (pinned to 95cc12e753)

Solutions

  1. Check RabbitMQ management plugin health and endpoint URL
  2. Retry transient server errors with backoff
  3. Verify no reverse proxy is intercepting the request
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at plugins/services/rabbitmq.go:131 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of shadow1ng/fscan@95cc12e753 (2026-09-06). Data as JSON: /api/errors/cc83a46823fba800. Report an issue: GitHub.