netgate-acl API (24.02)

This YANG module provides a Netgate-defined data-model for Access Control Lists.

Copyright 2017-2020 Rubicon Communications, LLC.

acl-config

returns netgate.acl.AclConfig

get /data/netgate-acl:acl-config

Example URL

https://hostname/restconf/data/netgate-acl:acl-config

Access Control Lists (ACL) data needed to support VPP.

Responses

200

netgate.acl.AclConfig

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-config-wrapper":
    {
    }
}

creates netgate.acl.AclConfig

post /data/netgate-acl:acl-config

Example URL

https://hostname/restconf/data/netgate-acl:acl-config

Access Control Lists (ACL) data needed to support VPP.

Request Body schema: application/yang-data+json

netgate.acl.AclConfig to be added to list

netgate-acl:acl-config
object (netgate.acl.AclConfig)

Responses

201

Object created

400

Internal error

409

Object already exists

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-config":
    {
    }
}

creates or updates netgate.acl.AclConfig

put /data/netgate-acl:acl-config

Example URL

https://hostname/restconf/data/netgate-acl:acl-config

Access Control Lists (ACL) data needed to support VPP.

Request Body schema: application/yang-data+json

netgate.acl.AclConfig to be added or updated

netgate-acl:acl-config-wrapper
object (netgate.acl.AclConfigWrapper)

Responses

201

Object created

204

Object modified

400

Internal error

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-config-wrapper":
    {
    }
}

removes netgate.acl.AclConfig

delete /data/netgate-acl:acl-config

Example URL

https://hostname/restconf/data/netgate-acl:acl-config

Access Control Lists (ACL) data needed to support VPP.

Responses

204

Object deleted

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

returns netgate.acl.aclconfig.AclTable

get /data/netgate-acl:acl-config/acl-table

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table

Table of ACL lists, indexed by name. Each entry contains a set of ACL Rules ordered by sequence number.

Responses

200

netgate.acl.aclconfig.AclTable

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-table-wrapper":
    {
    }
}

creates netgate.acl.aclconfig.AclTable

post /data/netgate-acl:acl-config/acl-table

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table

Table of ACL lists, indexed by name. Each entry contains a set of ACL Rules ordered by sequence number.

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.AclTable to be added to list

acl-table
object (netgate.acl.aclconfig.AclTable)

Responses

201

Object created

400

Internal error

409

Object already exists

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "acl-table":
    {
    }
}

creates or updates netgate.acl.aclconfig.AclTable

put /data/netgate-acl:acl-config/acl-table

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table

Table of ACL lists, indexed by name. Each entry contains a set of ACL Rules ordered by sequence number.

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.AclTable to be added or updated

netgate-acl:acl-table-wrapper
object (netgate.acl.aclconfig.AclTableWrapper)

Responses

201

Object created

204

Object modified

400

Internal error

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-table-wrapper":
    {
    }
}

removes netgate.acl.aclconfig.AclTable

delete /data/netgate-acl:acl-config/acl-table

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table

Table of ACL lists, indexed by name. Each entry contains a set of ACL Rules ordered by sequence number.

Responses

204

Object deleted

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

creates netgate.acl.aclconfig.acltable.AclList

post /data/netgate-acl:acl-config/acl-table/acl-list

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list

ACL list name.

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.acltable.AclList to be added to list

acl-list
object (netgate.acl.aclconfig.acltable.AclList)

Responses

201

Object created

400

Internal error

409

Object already exists

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "acl-list":
    {
    }
}

returns netgate.acl.aclconfig.acltable.AclList

get /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}

ACL list name.

path Parameters
acl-name
required
string

Id of acl-list

Responses

200

netgate.acl.aclconfig.acltable.AclList

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list=%7Bacl-name%7D"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-list-wrapper":
    {
    }
}

creates or updates netgate.acl.aclconfig.acltable.AclList

put /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}

ACL list name.

path Parameters
acl-name
required
string

Id of acl-list

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.acltable.AclList to be added or updated

netgate-acl:acl-list-wrapper
object (netgate.acl.aclconfig.acltable.AclListWrapper)

Responses

201

Object created

204

Object modified

400

Internal error

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-list-wrapper":
    {
    }
}

removes netgate.acl.aclconfig.acltable.AclList

delete /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}

ACL list name.

path Parameters
acl-name
required
string

Id of acl-list

Responses

204

Object deleted

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list=%7Bacl-name%7D"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

returns netgate.acl.aclconfig.acltable.acllist.AclRules

get /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

ACL Rule Table ordered by sequence number.

path Parameters
acl-name
required
string

Id of acl-list

Responses

200

netgate.acl.aclconfig.acltable.acllist.AclRules

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list=%7Bacl-name%7D/acl-rules"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-rules-wrapper":
    {
    }
}

creates netgate.acl.aclconfig.acltable.acllist.AclRules

post /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

ACL Rule Table ordered by sequence number.

path Parameters
acl-name
required
string

Id of acl-list

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.acltable.acllist.AclRules to be added to list

acl-rules
object (netgate.acl.aclconfig.acltable.acllist.AclRules)

Responses

201

Object created

400

Internal error

409

Object already exists

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "acl-rules":
    {
    }
}

creates or updates netgate.acl.aclconfig.acltable.acllist.AclRules

put /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

ACL Rule Table ordered by sequence number.

path Parameters
acl-name
required
string

Id of acl-list

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.acltable.acllist.AclRules to be added or updated

netgate-acl:acl-rules-wrapper
object (netgate.acl.aclconfig.acltable.acllist.AclRulesWrapper)

Responses

201

Object created

204

Object modified

400

Internal error

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-rules-wrapper":
    {
    }
}

removes netgate.acl.aclconfig.acltable.acllist.AclRules

delete /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules

ACL Rule Table ordered by sequence number.

path Parameters
acl-name
required
string

Id of acl-list

Responses

204

Object deleted

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list=%7Bacl-name%7D/acl-rules"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

creates netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule

post /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule

A List of ACL Rules.

path Parameters
acl-name
required
string

Id of acl-list

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule to be added to list

acl-rule
object (netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule)

Responses

201

Object created

400

Internal error

409

Object already exists

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "acl-rule":
    {
    }
}

returns netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule

get /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

A List of ACL Rules.

path Parameters
acl-name
required
string

Id of acl-list

sequence
required
integer <int64>

Id of acl-rule

Responses

200

netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list=%7Bacl-name%7D/acl-rules/acl-rule=%7Bsequence%7D"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-rule-wrapper":
    {
    }
}

creates or updates netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule

put /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

A List of ACL Rules.

path Parameters
acl-name
required
string

Id of acl-list

sequence
required
integer <int64>

Id of acl-rule

Request Body schema: application/yang-data+json

netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule to be added or updated

netgate-acl:acl-rule-wrapper
object (netgate.acl.aclconfig.acltable.acllist.aclrules.AclRuleWrapper)

Responses

201

Object created

204

Object modified

400

Internal error

Request samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-rule-wrapper":
    {
    }
}

removes netgate.acl.aclconfig.acltable.acllist.aclrules.AclRule

delete /data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

Example URL

https://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

A List of ACL Rules.

path Parameters
acl-name
required
string

Id of acl-list

sequence
required
integer <int64>

Id of acl-rule

Responses

204

Object deleted

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-config/acl-table/acl-list=%7Bacl-name%7D/acl-rules/acl-rule=%7Bsequence%7D"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

acl-state

returns netgate.acl.AclState

get /data/netgate-acl:acl-state

Example URL

https://hostname/restconf/data/netgate-acl:acl-state

Access Control Lists (ACL) state data.

Responses

200

netgate.acl.AclState

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-state"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-state-wrapper":
    {
    }
}

returns netgate.acl.aclstate.AclTable

get /data/netgate-acl:acl-state/acl-table

Example URL

https://hostname/restconf/data/netgate-acl:acl-state/acl-table

Table of ACL lists, indexed by name. Each entry contains a set of ACL Rules ordered by sequence number.

Responses

200

netgate.acl.aclstate.AclTable

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-state/acl-table"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-table-wrapper":
    {
    }
}

returns netgate.acl.aclstate.acltable.AclList

get /data/netgate-acl:acl-state/acl-table/acl-list={acl-name}

Example URL

https://hostname/restconf/data/netgate-acl:acl-state/acl-table/acl-list={acl-name}

ACL list name.

path Parameters
acl-name
required
string

Id of acl-list

Responses

200

netgate.acl.aclstate.acltable.AclList

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-state/acl-table/acl-list=%7Bacl-name%7D"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-list-wrapper":
    {
    }
}

returns netgate.acl.aclstate.acltable.acllist.AclRules

get /data/netgate-acl:acl-state/acl-table/acl-list={acl-name}/acl-rules

Example URL

https://hostname/restconf/data/netgate-acl:acl-state/acl-table/acl-list={acl-name}/acl-rules

ACL Rule Table ordered by sequence number.

path Parameters
acl-name
required
string

Id of acl-list

Responses

200

netgate.acl.aclstate.acltable.acllist.AclRules

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-state/acl-table/acl-list=%7Bacl-name%7D/acl-rules"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-rules-wrapper":
    {
    }
}

returns netgate.acl.aclstate.acltable.acllist.aclrules.AclRule

get /data/netgate-acl:acl-state/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

Example URL

https://hostname/restconf/data/netgate-acl:acl-state/acl-table/acl-list={acl-name}/acl-rules/acl-rule={sequence}

A List of ACL Rules.

path Parameters
acl-name
required
string

Id of acl-list

sequence
required
integer <int64>

Id of acl-rule

Responses

200

netgate.acl.aclstate.acltable.acllist.aclrules.AclRule

400

Internal error

Request samples

Copy
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "http://hostname/restconf/data/netgate-acl:acl-state/acl-table/acl-list=%7Bacl-name%7D/acl-rules/acl-rule=%7Bsequence%7D"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := ioutil.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}

Response samples

Content type
application/yang-data+json
Copy
Expand all Collapse all
{
  • "netgate-acl:acl-rule-wrapper":
    {
    }
}