search for: access_control

Displaying 20 results from an estimated 22 matches for "access_control".

2007 May 24
3
Help with Create and Update with options_for_select in a select_tag
...e has_many AccessControl AccessControl belongs_to Service application.rb ------------------------- $types = Array["Athens", "htpasswd", "IP", "None", "Other", "Password", "Shibboleth"] View: --------------- <% if @service.access_controls @types = @service.access_controls.collect{|a| a.value}.join('' '') end %> <label for="access_control_value"><span class = "required">*</ span>Access Control:</label> <%=select_tag ''access_control[]'', option...
2007 May 24
1
How do I show the selected values in options_for_select? Not as simple as it sounds.
How do I show the selected values in options_for_select? I have a Service model and a AccessControl model. When a user edits a Service I want the services access_controls to be pre-selected. Models: Service has_many AccessControls AccessControl belongs_to Service application.rb: $types = Array["Athens", "htpasswd", "IP", "None", "Other", "Password", "Shibboleth"] View: % if @service.access_...
2006 Jul 16
9
acl_system help is needed
i found Ezra''s acl_system plugin yesterday and i am trying to figure it out. based on the simple instructions on the site, it does exactly what i need but i''m getting some errors when i try to use it: NoMethodError in UsersController#index You have a nil object when you didn''t expect it! The error occured while evaluating nil.roles i am pretty new to rails and
2006 Aug 05
2
acl_system2 undefined method `access_control''
..._system2 Then I installed the lib and test >ruby script\plugin install lib >ruby script\plugin install test Created the role.rb model, etc. as per the readme file, then added this to one of my controllers: class CountryController < ApplicationController before_filter :login_required access_control [:new, :create, :update, :edit] => ''(administrator)'' ... end and get the following error when I call an action on this controller: undefined method `access_control'' for CountryController:Class I''m guessing there is more to installing this plugin? A...
2006 Mar 22
4
Problem with ACL plugin system
...lowing error: NoMethodError in Admin#index protected method `access_denied'' called for #<AdminController:0x408fc9a8> RAILS_ROOT: script/../config/.. Application Trace | Framework Trace | Full Trace ./script/../config/../vendor/plugins/acl_system/lib/caboose/access_control.rb:24:in `access_control'' The prob seems to be in the following code block: 23 if c.respond_to?(:access_denied) 24 c.access_denied 25 else 26 c.send(:render_text, "You have insufficient permissions to access #{c.controller_name}/#{c.ac...
2007 Sep 25
4
[XSM:ACM] When cw is used, dom0 reboots.
...mdisk = "/boot/initrd-2.6.18-xenU.img" memory = "128" ~~~~ name = "vm1" disk = [ ''file:/xen/vm1.img,sda1,w'' ] vif = [ '''' ] root = "/dev/sda1 ro" on_xend_stop = "suspend" extra = "3 xencons=tty" access_control = [''policy=example.client_v1,label=dom_HomeBanking''] #cat vm4.conf kernel = "/boot/vmlinuz-2.6.18-xen" ramdisk = "/boot/initrd-2.6.18-xenU.img" memory = "128" ~~~~~ name = "vm4" disk = [ ''file:/xen/vm4.img,sda1,w''...
2006 Feb 23
13
Check if a saved user''s name is admin
Hi all, I have a question about this method in my User model: # Returns true for the (saved) user called "admin" def is_the_administrator true if save and name == "admin" end The method returns true if the user''s name is admin. However, I only want to return true if the state of the object is "saved", so I call the save method first. I''m
2008 Sep 12
3
[XSM][Patch] Minor XSM tools patch to dummy module - implement missing stub
- This minor patch implements the missing stub function security_label_to_details in the dummy module. This stub function is necessary to create domains with network interfaces for modules that do not implement the security_label_to_details function. Signed-off-by: George Coker <gscoker@alpha.ncsc.mil> _______________________________________________ Xen-devel mailing list
2006 Dec 20
0
[Xense-devel] [PATCH] [3/4] Flask XSM tools
...or the xen control plane (xm & xend). The patch also refactors the ACM toolchain so that a common security API (based on the existing ACM toolchain) is exported to xm and xend. To create a domain with the Flask module, add the following (for example) to a domain''s configuration file access_control = ["policy=,label=system_u:object_r:domU_t"] This will cause a domain to be created with the label "system_u:object_r:domU_t". Flask does not use the policy value in the access_control structure. Signed-off-by: George Coker <gscoker@alpha.ncsc.mil> ___________________...
2006 Feb 21
0
acl_system plugin first look
...ntioned above. Lets see the candy here fist. This is what it looks like to use this to protect your controller actions using roles and & | ! to define complex permissions. class PostController < ApplicationController before_filter :login_required, :except => [:list, :index] access_control [:new, :create] => ''(admin | user | moderator) & ! blacklist'', [:update, :delete] => ''(admin | moderator) & !blacklist'', :approve => ''admin & (!moderator | ! blacklist...
2007 Dec 19
1
Error: Not enough memory is available, and dom0 cannot be shrunk any further
...21-6.fc7xen" ramdisk = "/boot/initrd-2.6.21-6.fc7xen.img" root="/dev/sda1 ro" memory = 128 name = "fedora.fc6" vifs = [ '''' ] dhcp = "dhcp" disk = [''tap:aio://etc//xen//rpath.img,sda1,w''] extra = "selinux=0 3" access_control = [''policy=dept,label=CSE''] Using the binaries of yum install xen kernel-xen I am able to start the domain using the same config file. Thanks, Hayawardh _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource...
2008 May 14
7
A copy of XX has been removed from the module tree but is still active!
I have a class in my /lib/ directory called tracker.rb It''s function is to receive an array of URLs and then perform 4 separate tasks on each URL Each of the 4 tasks gets it''s own thread. the class is called from my controller like: output = Tracker.go([array_of_urls]) Sometimes, when it hits an exception, instead of just dieing gracefully, my logs repeatedly display: A
2006 Jun 26
0
How to limit access to model objects based on role?
...ues will depend on the user''s role. I hope all this make sense :) On top of all this, I''m using Ezra''s access control plugin to limit access to the controllers. So my question is: is there a better way to do this? class CategoriesController < ApplicationController access_control :DEFAULT => ''(Administrator | SuperUser)'' def edit set_category_with_scope(params[:id]) end def update set_category_with_scope(params[:id]) @category.update_attributes(params[:category]) end def set_category_with_scope(*args) Category.with_scope(:find => scoped_op...
2006 May 10
0
Ezra''s acl_system2 and flash not getting populated in functional tests
...ave written some functional tests to check for correct handling of redirects, flashes, etc. The flashes however only get populated on the first get action in any given test. Here is what I have so far: In the controller: class PageController < AC before_filter => :login_required access_control :DEFAULT => ''admin'' def index end ... protected def permission_denied flash[:message] = "You must log in as an administrator." redirect_to :controller => "account", :action => "login end end In the test: ACTIONS = [...
2007 Aug 05
0
(yet another) AccessControl Plugin
...it''s yet another ACL system for Rails available as plugin. API-Doc: http://www.oniversus.com/ Please read the API-Docs to see if it fit your needs - I need testers though... To install it straight to a test project of yours run: script/plugin install \ http://svn.oniversus.com/projects/access_control_sandbox/vendor/plugins/access_control Response (as always) desired. Cheers Florian --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrai...
2007 Oct 18
0
ACL System restrict_to
Does the restrict_to method only work in the views for some reason? I have tried it in the controller and i get the "undefined local variable or method `restrict_to'' for Admin::SurveysController:Class" Ive even copied the code from the access_control.rb in the plugin to the application_helper but it still keeps giving the same error. def restrict_to(logicstring, context = {}) return false if current_user.nil? result = '''' if permit?(logicstring, context) result = yield if block_given? end...
2007 Jul 06
3
stubbing helper methods for View specs
.../show.haml 56: - @user.roles.each do |role| 57: = role.title 58: 59: - restrict_to "admin | projektleiter" do 60: = link_to "Bearbeiten", edit_user_url(@user) app/views//users/show.haml:59 vendor/plugins/acl_system2/lib/caboose/access_control.rb:75:in `restrict_to'' (eval):2:in `restrict_to'' (eval):164:in `_render_haml_1'' vendor/plugins/haml/lib/haml/engine.rb:435:in `compile'' vendor/plugins/haml/lib/haml/engine.rb:186:in `to_html'' vendor/plugins/haml/lib/haml/templa...
2007 Aug 11
2
Rspec and acl_system2 plugin
...cles Publications </li> 27: </ul> 28: <% restrict_to "admin" do -%> 29: <ul id="admin-tabs"> 30: <li> /users Utilisateurs </li> 31: </ul> #{RAILS_ROOT}/vendor/plugins/acl_system2/lib/caboose/access_control.rb:75:in `restrict_to'' (eval):2:in `send'' (eval):2:in `restrict_to'' #{RAILS_ROOT}/app/views/layouts/admin.rhtml:28:in `_run_rhtml_47app47views47layouts47admin46rhtml'' /usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/action_view/base.rb:326:...
2006 Feb 20
6
LoginGenerator - multiple user types...
I have been looking at the LoginGenerator gem. Looks great and can be easily modified. However in my app I have two places where people can login, one is for in my case "employees" the other is for "users". They are seperate tables in my database and have many different fields. I have an admin area located at ./sysadmin/ where only "employees" can login, they
2006 Jul 28
12
MenuEngine
Hi all, MenuEngine is a small Rails engine that can generate templated drop-down DHTML menus commonly used for web site navigation. Supports creation of menus from a YAML file, from code and from pre-configured HTML. Optionally integrates with UserEngine for authorization. http://www.muermann.org/ruby/menu_engine Project page: http://rubyforge.org/projects/menuengine This is my first attempt