working on vtl features: pending drive creation, media changer creation, iscsi mapping
This commit is contained in:
@@ -113,6 +113,7 @@ func (a *App) isPublicEndpoint(path, method string) bool {
|
||||
"/storage", // Storage management page
|
||||
"/shares", // Shares page
|
||||
"/iscsi", // iSCSI page
|
||||
"/vtl", // VTL (Virtual Tape Library) page
|
||||
"/protection", // Data Protection page
|
||||
"/management", // System Management page
|
||||
"/api/docs", // API documentation
|
||||
@@ -138,17 +139,22 @@ func (a *App) isPublicEndpoint(path, method string) bool {
|
||||
// SECURITY: Only GET requests are allowed without authentication
|
||||
// POST, PUT, DELETE, PATCH require authentication
|
||||
publicReadOnlyPaths := []string{
|
||||
"/api/v1/dashboard", // Dashboard data
|
||||
"/api/v1/disks", // List disks
|
||||
"/api/v1/pools", // List pools (GET only)
|
||||
"/api/v1/pools/available", // List available pools
|
||||
"/api/v1/datasets", // List datasets (GET only)
|
||||
"/api/v1/zvols", // List ZVOLs (GET only)
|
||||
"/api/v1/shares/smb", // List SMB shares (GET only)
|
||||
"/api/v1/exports/nfs", // List NFS exports (GET only)
|
||||
"/api/v1/iscsi/targets", // List iSCSI targets (GET only)
|
||||
"/api/v1/snapshots", // List snapshots (GET only)
|
||||
"/api/v1/snapshot-policies", // List snapshot policies (GET only)
|
||||
"/api/v1/dashboard", // Dashboard data
|
||||
"/api/v1/disks", // List disks
|
||||
"/api/v1/pools", // List pools (GET only)
|
||||
"/api/v1/pools/available", // List available pools
|
||||
"/api/v1/datasets", // List datasets (GET only)
|
||||
"/api/v1/zvols", // List ZVOLs (GET only)
|
||||
"/api/v1/shares/smb", // List SMB shares (GET only)
|
||||
"/api/v1/exports/nfs", // List NFS exports (GET only)
|
||||
"/api/v1/iscsi/targets", // List iSCSI targets (GET only)
|
||||
"/api/v1/vtl/status", // VTL status (GET only)
|
||||
"/api/v1/vtl/drives", // List VTL drives (GET only)
|
||||
"/api/v1/vtl/tapes", // List VTL tapes (GET only)
|
||||
"/api/v1/vtl/changers", // List VTL media changers (GET only)
|
||||
"/api/v1/vtl/changer/status", // VTL media changer status (GET only)
|
||||
"/api/v1/snapshots", // List snapshots (GET only)
|
||||
"/api/v1/snapshot-policies", // List snapshot policies (GET only)
|
||||
}
|
||||
|
||||
for _, publicPath := range publicReadOnlyPaths {
|
||||
|
||||
Reference in New Issue
Block a user