Bottle cheat sheets part 3

Actually i know how bottle access privileges is complex as it doesn’t work alone but it cooperate with lists and lists components change with each access privilege .but what makes its complexity greet it can allow access to mega clients up to ip or user or subscriber .each files box has five access privileges ( Visitors – Users – Subscriptions – Users & Subscriptions – Hidden ) .the following table shows allowed Requests and other will denied

  • Access PrivilegeAllowed Requests
  • VisitorsAll ips
  • UsersAll users
  • SubscriptionsAll subscribers
  • Users & SubscriptionsBoth users and subscribers
  • Hiddensome users

Notice : bottle allow administrators to set minimum user role for all its pages and actions (add – edit – trash … exist in each page) so users allowed to access in hidden privilege who can access files page .

Previous discussion related to bottle default access privileges but what if you like to allow all users to access definite files box and deny access for one or many users .now you need lists to filter custom users .the following table shows lists components for each access privilege

  • Access Privilege list components
  • VisitorsReject IPS
  • UsersAllow Subscriptions
  • Allow IPS
  • Reject Users
  • Reject IPS
  • SubscriptionsAllow Users
  • Allow IPS
  • Reject Subscriptions
  • Reject IPS
  • Users & SubscriptionsAllow IPS
  • Reject Users
  • Reject Subscriptions
  • Reject IPS
  • HiddenAllow IPS

Notice : bottle automatically detect ips of anyone visit front download page and fetched then in allow and deny ips select box and also you can import some ips stuff using import ips tools exist in tools page.