Module ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias alias ImportFrom alias alias ClassDef bases NameLoad body Assign NameStore ListLoad Call AttributeLoad NameLoad attr ListLoad Str ListLoad Str Str Call AttributeLoad NameLoad attr ListLoad Str ListLoad Str FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword Num keyword Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword Num keyword Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr attr NameLoad NameLoad keyword NameLoad Assign NameStore ListLoad For NameStore AttributeLoad NameLoad attr body Assign NameStore Call NameLoad AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Dict Str Str Str Str Str AttributeLoad NameLoad attr Call NameLoad NameLoad AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Return TupleLoad NameLoad Num decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword NameLoad keyword Str keyword Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword NameLoad keyword Str keyword Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword NameLoad keyword Str keyword Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad If NameLoad body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call NameLoad AttributeLoad NameLoad attr NameLoad Assign SubscriptStore NameLoad Index Str AttributeLoad NameLoad attr Return TupleLoad NameLoad Num decorator_list decorator_list ClassDef bases NameLoad body Assign NameStore ListLoad Call AttributeLoad NameLoad attr ListLoad Str ListLoad Str Str Str FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr CompareEq AttributeLoad NameLoad attr NameLoad attr If UnaryOpNot NameLoad body Return TupleLoad Dict Str Str Num Assign NameStore Call NameLoad AttributeLoad NameLoad attr NameLoad Assign SubscriptStore NameLoad Index Str AttributeLoad NameLoad attr Return TupleLoad NameLoad Num decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword NameLoad keyword Str keyword Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword NameLoad keyword Str keyword Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword NameLoad keyword Str keyword Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr CompareEq AttributeLoad NameLoad attr NameLoad attr If UnaryOpNot NameLoad body Return TupleLoad Dict Str Str Num Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call NameLoad AttributeLoad NameLoad attr NameLoad Assign SubscriptStore NameLoad Index Str AttributeLoad NameLoad attr Return TupleLoad NameLoad Num decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign TupleStore NameStore NameStore Call NameLoad AttributeLoad NameLoad attr If NameLoad body Return NameLoad Expr Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr CompareEq AttributeLoad NameLoad attr NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr Return TupleLoad Dict Str Str Num decorator_list decorator_list
N/A security_monkey.views AuthenticatedService security_monkey.views __check_auth__ security_monkey.views WHITELIST_FIELDS security_monkey.datastore NetworkWhitelistEntry security_monkey db rbac flask_restful marshal reqparse WhitelistListPost N/A AuthenticatedService N/A N/A decorators N/A N/A N/A rbac allow N/A Admin N/A GET POST N/A N/A rbac allow N/A View N/A GET get N/A N/A self N/A N/A N/A 
            .. http:get:: /api/1/whitelistcidrs

            Get a list of CIDR's whitelisted to be used in security groups.

            **Example Request**:

            .. sourcecode:: http

                GET /api/1/whitelistcidrs HTTP/1.1
                Host: example.com
                Accept: application/json, text/javascript

            **Example Response**:

            .. sourcecode:: http

                HTTP/1.1 200 OK
                Vary: Accept
                Content-Type: application/json

                {
                    count: 1,
                    items: [
                        {
                            "id": 123,
                            "name": "Corp",
                            "notes": "Corporate Network",
                            "cidr": "1.2.3.4/22"
                        },
                    ],
                    total: 1,
                    page: 1,
                    auth: {
                        authenticated: true,
                        user: "user@example.com"
                    }
                }

            :statuscode 200: no error
            :statuscode 401: Authentication failure. Please login.
         N/A N/A N/A N/A self reqparse add_argument count type int default 30 location args N/A N/A N/A N/A self reqparse add_argument page type int default 1 location args N/A args N/A N/A N/A self reqparse parse_args N/A page N/A N/A args pop page None N/A count N/A N/A args pop count None N/A result N/A N/A N/A N/A N/A NetworkWhitelistEntry query order_by N/A NetworkWhitelistEntry id paginate page count error_out False N/A items N/A N/A entry N/A result items N/A N/A whitelistentry_marshaled N/A marshal N/A entry __dict__ WHITELIST_FIELDS N/A N/A N/A items append whitelistentry_marshaled N/A marshaled_dict N/A total count page items auth N/A result total N/A len items N/A result page items N/A self auth_dict N/A N/A marshaled_dict 200 N/A post N/A N/A self N/A N/A N/A 
            .. http:post:: /api/1/whitelistcidrs

            Create a new CIDR whitelist entry.

            **Example Request**:

            .. sourcecode:: http

                POST /api/1/whitelistcidrs HTTP/1.1
                Host: example.com
                Accept: application/json

                {
                    "name": "Corp",
                    "notes": "Corporate Network",
                    "cidr": "1.2.3.4/22"
                }

            **Example Response**:

            .. sourcecode:: http

                HTTP/1.1 201 Created
                Vary: Accept
                Content-Type: application/json

                {
                    "id": 123,
                    "name": "Corp",
                    "notes": "Corporate Network",
                    "cidr": "1.2.3.4/22"
                }

            :statuscode 201: created
            :statuscode 401: Authentication Error. Please Login.
         N/A N/A N/A N/A self reqparse add_argument name required True type unicode help Must provide account name location json N/A N/A N/A N/A self reqparse add_argument cidr required True type unicode help Network CIDR required. location json N/A N/A N/A N/A self reqparse add_argument notes required False type unicode help Add context. location json N/A args N/A N/A N/A self reqparse parse_args N/A name N/A args N/A name N/A cidr N/A N/A args get cidr True N/A notes N/A N/A args get notes None N/A whitelist_entry N/A NetworkWhitelistEntry N/A N/A whitelist_entry name name N/A N/A whitelist_entry cidr cidr N/A notes N/A N/A N/A whitelist_entry notes notes N/A N/A N/A N/A db session add whitelist_entry N/A N/A N/A N/A db session commit N/A N/A N/A N/A db session refresh whitelist_entry N/A whitelistentry_marshaled N/A marshal N/A whitelist_entry __dict__ WHITELIST_FIELDS N/A N/A whitelistentry_marshaled N/A auth N/A self auth_dict N/A N/A whitelistentry_marshaled 201 N/A N/A WhitelistGetPutDelete N/A AuthenticatedService N/A N/A decorators N/A N/A N/A rbac allow N/A Admin N/A GET PUT DELETE __init__ N/A N/A self N/A N/A N/A N/A self reqparse N/A N/A reqparse RequestParser N/A N/A N/A N/A super WhitelistGetPutDelete self __init__ N/A get N/A N/A self item_id N/A N/A N/A 
            .. http:get:: /api/1/whitelistcidrs/<int:id>

            Get the whitelist entry with the given ID.

            **Example Request**:

            .. sourcecode:: http

                GET /api/1/whitelistcidrs/123 HTTP/1.1
                Host: example.com
                Accept: application/json, text/javascript

            **Example Response**:

            .. sourcecode:: http

                HTTP/1.1 200 OK
                Vary: Accept
                Content-Type: application/json

                {
                    "id": 123,
                    "name": "Corp",
                    "notes": "Corporate Network",
                    "cidr": "1.2.3.4/22",
                    auth: {
                        authenticated: true,
                        user: "user@example.com"
                    }
                }

            :statuscode 200: no error
            :statuscode 404: item with given ID not found
            :statuscode 401: Authentication failure. Please login.
         N/A result N/A N/A N/A N/A N/A NetworkWhitelistEntry query filter N/A N/A NetworkWhitelistEntry id item_id first N/A N/A result N/A N/A N/A N/A status Whitelist entry with the given ID not found. 404 N/A whitelistentry_marshaled N/A marshal N/A result __dict__ WHITELIST_FIELDS N/A N/A whitelistentry_marshaled N/A auth N/A self auth_dict N/A N/A whitelistentry_marshaled 200 N/A put N/A N/A self item_id N/A N/A N/A 
            .. http:get:: /api/1/whitelistcidrs/<int:id>

            Update the whitelist entry with the given ID.

            **Example Request**:

            .. sourcecode:: http

                PUT /api/1/whitelistcidrs/123 HTTP/1.1
                Host: example.com
                Accept: application/json, text/javascript

                {
                    "id": 123,
                    "name": "Corp",
                    "notes": "Corporate Network - New",
                    "cidr": "2.2.0.0/16"
                }

            **Example Response**:

            .. sourcecode:: http

                HTTP/1.1 200 OK
                Vary: Accept
                Content-Type: application/json

                {
                    "id": 123,
                    "name": "Corp",
                    "notes": "Corporate Network - New",
                    "cidr": "2.2.0.0/16",
                    auth: {
                        authenticated: true,
                        user: "user@example.com"
                    }
                }

            :statuscode 200: no error
            :statuscode 404: item with given ID not found
            :statuscode 401: Authentication failure. Please login.
         N/A N/A N/A N/A self reqparse add_argument name required True type unicode help Must provide account name location json N/A N/A N/A N/A self reqparse add_argument cidr required True type unicode help Network CIDR required. location json N/A N/A N/A N/A self reqparse add_argument notes required False type unicode help Add context. location json N/A args N/A N/A N/A self reqparse parse_args N/A name N/A args N/A name N/A cidr N/A N/A args get cidr True N/A notes N/A N/A args get notes None N/A result N/A N/A N/A N/A N/A NetworkWhitelistEntry query filter N/A N/A NetworkWhitelistEntry id item_id first N/A N/A result N/A N/A N/A N/A status Whitelist entry with the given ID not found. 404 N/A N/A result name name N/A N/A result cidr cidr N/A N/A result notes notes N/A N/A N/A N/A db session add result N/A N/A N/A N/A db session commit N/A N/A N/A N/A db session refresh result N/A whitelistentry_marshaled N/A marshal N/A result __dict__ WHITELIST_FIELDS N/A N/A whitelistentry_marshaled N/A auth N/A self auth_dict N/A N/A whitelistentry_marshaled 200 N/A delete N/A N/A self item_id N/A N/A N/A 
            .. http:delete:: /api/1/whitelistcidrs/123

            Delete a network whitelist entry.

            **Example Request**:

            .. sourcecode:: http

                DELETE /api/1/whitelistcidrs/123 HTTP/1.1
                Host: example.com
                Accept: application/json

            **Example Response**:

            .. sourcecode:: http

                HTTP/1.1 202 Accepted
                Vary: Accept
                Content-Type: application/json

                {
                    'status': 'deleted'
                }

            :statuscode 202: accepted
            :statuscode 401: Authentication Error. Please Login.
         N/A N/A auth retval N/A __check_auth__ N/A self auth_dict N/A auth N/A N/A retval N/A N/A N/A N/A N/A N/A NetworkWhitelistEntry query filter N/A N/A NetworkWhitelistEntry id item_id delete N/A N/A N/A N/A db session commit N/A N/A N/A status deleted 202 N/A N/A