PhpBB forum ext needed, to restrict posts per user, per day, per subforum

Hello!

As things are today, there is no extension available for something I would seek for a phpBB forum, so I'm asking here to the Digitalpoint coders.

*

More details about the phpBB extension:

– it has to limit the number of posts (new threads and and replies inside a thread, both are added to the count, AKA both count) that a username is allowed to post, in each subforum, every day.

Out of my ass example: if the limit is set to 5, and the admin decides it applies to the "Casual…

PhpBB forum ext needed, to restrict posts per user, per day, per subforum

How to restrict SharePoint permissions for below senerio?

We have a SharePoint integration with CRM.

CRM creates document libraries, folders and document from its system. Back-end is SharePoint.

From CRM system, users cannot access the files created by other users, but how ever users started accessing back end SharePoint site directly to access the files and folders created by other users.

In SharePoint the permissions are inherited from parent site, breaking inheritance is one option but that option could be very tedious as maintain permissions for 300 folders could be difficult.

Is there anyway we can restrict users from access the SharePoint site directly? Or is there any better solution for the above scenario?

Restrict DHCP lease range using NetworkManager “Shared to other computers”

My computer has wireless internet access and I successfully share its connection using the built-in “Shared to other computers” feature of Network Manager:

enter image description here

However, I’m only serving a single host (via cross-over cable) and because DHCP is used, the IP address of my host is indeterminate. I can’t save ssh or VNC connections because the route will change without warning.

  • Can I restrict the DHCP range of shared connections to a single address?

My downstream host is Untouchable – it’s outside my scope to change its network configuration. What I need is more control over how Network Manager launches dnsmasq to support the internet connection sharing. It seems to do so entirely with command line parameters:

lar@rpi-lgr13-0199:~$   ps ax | grep dnsmasq   817 ?        S      0:00 /usr/sbin/dnsmasq --conf-file --no-hosts --keep-in-foreground --bind-interfaces --except-interface=lo --clear-on-reload --strict-order --listen-address=10.42.0.1 --dhcp-range=10.42.0.10,10.42.0.254,60m --dhcp-option=option:router,10.42.0.1 --dhcp-lease-max=50 --pid-file=/var/run/nm-dnsmasq-enxb827eb017088.pid --conf-dir=/etc/NetworkManager/dnsmasq-shared.d  1013 ?        S      0:00 /usr/sbin/dnsmasq --no-resolv --keep-in-foreground --no-hosts --bind-interfaces --pid-file=/var/run/NetworkManager/dnsmasq.pid --listen-address=127.0.1.1 --cache-size=0 --conf-file=/dev/null --proxy-dnssec --enable-dbus=org.freedesktop.NetworkManager.dnsmasq --conf-dir=/etc/NetworkManager/dnsmasq.d  6987 pts/2    S+     0:00 grep --color=auto dnsmasq 

How to restrict apache web server file and folder access by group

I’m a newbie to apache webserver and I can’t seem to figure out how to restrict certain folders/files to members of different groups. For example:

userA is a member of groupA and not a member of groupB userB is a member of groupB and not a member of groupA 

I created their accounts, added them to their groups and added their password entries (using output from openssl passwd command) to the /etc/nginx/.htpasswd file.

I have the following directory structure in /var/www/testsite.company.com:

drwxr--r-- 2 root groupA           4096 Sep 25 17:42 GroupAFolder/ drwxr--r-- 2 root groupB           4096 Sep 25 12:04 GroupBFolder/ 

In /var/www/testsite.company.com/GroupAFolder I have:

-rwxr--r-- 1 root groupA  235 Sep 25 17:42 index.html (contains a link to groupAfile.exe so the user can download it) -rwxr--r-- 1 root groupA  235 Sep 25 17:42 groupAfile.exe 

In /var/www/testsite.company.com/GroupBFolder I have:

-rwxr--r-- 1 root groupB  235 Sep 25 17:42 index.html (contains a link to groupBfile.exe so the user can download it) -rwxr--r-- 1 root groupB  235 Sep 25 17:42 groupBfile.exe 

The file /etc/nginx/sites-enabled/testsite.company.com.conf has:

server {    listen 444 ssl http2;    listen [::]:444 ssl http2;    include snippets/self-signed.conf;    include snippets/ssl-params.conf;     server_name testsite.company.com;    root /var/www/testsite.company.com;    index index.html;     location / {          try_files $  uri $  uri/ = 404;          auth_basic "Password Required";          auth_basic_user_file /etc/nginx/.htpasswd;    } } 

I can log into https://testsite.company.com:444/GroupAFolder/ as userA and see the index.html web page and I can click on the groupAfile.exe link and download the file with the permissions set as listed above (rwxr–r–). But if I take away world read access on index.html and groupAfile.exe to limit any user not in groupA from accessing the webpage and executable file, my userA can no longer access them either. It is kinda weird behavior too. When I first change the permissions to rwxr—– and then log into https://testsite.company.com:444/GroupAFolder/ as userA, I get 403 Forbidden. But if I refresh the page, I can then see the index.html web page that has the link to download the file. But then, when I click on the link, I get the 403 Forbidden again for the executable and it stays that way.

Does anyone have an idea what I’m doing wrong or missing? Hopefully I haven’t made it too confusing.

How do I restrict an interpolated function to only take values > 0?

I have a list of points which looks like this when plotted with Joined -> True:

enter image description here

I’m interested in the area under the curve with x-axis > 0 as a ratio to the area under the curve as a whole. The obvious way to do this is to define function = Interpolation[list], then use Integrate[function[x],{x,0,Infinity}/Integrate[function[x]],{x,-Infinity,Infinity}].

However, for some of the parameters used to generate this plot, this ratio goes above one. My reading is that the interpolated function goes negative at some point. I know for physical reasons that the function is strictly positive (it is an unnormalized probability). Is there a way to feed this restriction to Interpolation, or perhaps to simply zero out the interpolated function past a certain point?

Edit: some explicit code that shows the problem I’m facing. For this list:

{{-2.,-1.5,-1.,-0.5,0.,0.5,1.,1.5,2.,2.5,3.,3.5,4.,4.5,5.},{2.447482917*10^-26,7.166525422*10^-23,6.828228711*10^-20,2.221078019*10^-17,2.603521623*10^-15,1.167198034*10^-13,2.134212354*10^-12,1.702246816*10^-11,6.341646627*10^-11,1.183984093*10^-10,1.195443416*10^-10,7.082172125*10^-11,2.655421922*10^-11,6.681130557*10^-12,1.175390799*10^-12}}

(first list is x-axis values, second list is y-axis values). Define interpolating function:

Testfunc = Interpolation[{2.447482916954607`*^-26, 7.166525421661271`*^-23, 6.82822871054717`*^-20, 2.2210780189277698`*^-17, 2.6035216228330743`*^-15, 1.1671980340015243`*^-13, 2.134212354193162`*^-12, 1.7022468159138925`*^-11, 6.341646627292107`*^-11, 1.1839840933620157`*^-10, 1.195443415545412`*^-10, 7.082172125430078`*^-11, 2.655421922388246`*^-11, 6.681130557379854`*^-12, 1.1753907990705456`*^-12}]

Take the numerical integral: NIntegrate[Testfunc[x], {x, 5, 15}]/NIntegrate[Testfunc[x], {x, 1, 15}]

Result is: 1.000008312

Restrict a shipping package in woocommerce to ship to only one country

I have created shipping packages for my store to set different shipping options for different products. Now I want one shipping package to restrict only for UK, so that means if the user selects UK, it shows the shipping options and if it is any other country, then it simply shows a note there that ‘This product can’t be shipped to your country’. Right now it shows “No shipping options were found for your country.”

Here is the code for shipping packages:

function custom_split_shipping_packages_shipping_class( $  packages ) { // Reset all packages $  packages              = array(); $  regular_package_items = array(); $  tr_package_items   = array(); $  sr_package_items   = array(); $  tr_shipping_class = 'tr-box'; // Tr Shipping class slug $  sr_shipping_class = 'sr-box'; // Sr Shipping class slug foreach ( WC()->cart->get_cart() as $  item_key => $  item ) {     if ( $  item['data']->needs_shipping() ) {         if ( $  tr_shipping_class == $  item['data']->get_shipping_class() ) {             $  tr_package_items[ $  item_key ] = $  item;         } else if ( $  sr_shipping_class == $  item['data']->get_shipping_class() ) {             $  sr_package_items[ $  item_key ] = $  item;         } else {             $  regular_package_items[ $  item_key ] = $  item;         }     } } // Create shipping packages if ( $  regular_package_items ) {     $  packages[] = array(         'contents'        => $  regular_package_items,         'contents_cost'   => array_sum( wp_list_pluck( $  regular_package_items, 'line_total' ) ),         'applied_coupons' => WC()->cart->get_applied_coupons(),         'user'            => array(              'ID' => get_current_user_id(),         ),         'destination'    => array(             'country'    => WC()->customer->get_shipping_country(),             'state'      => WC()->customer->get_shipping_state(),             'postcode'   => WC()->customer->get_shipping_postcode(),             'city'       => WC()->customer->get_shipping_city(),             'address'    => WC()->customer->get_shipping_address(),             'address_2'  => WC()->customer->get_shipping_address_2()         )     ); } if ( $  tr_package_items ) {     $  packages[] = array(         'contents'        => $  tr_package_items,         'contents_cost'   => array_sum( wp_list_pluck( $  tr_package_items, 'line_total' ) ),         'applied_coupons' => WC()->cart->get_applied_coupons(),         'user'            => array(              'ID' => get_current_user_id(),         ),         'destination'    => array(             'country'    => WC()->customer->get_shipping_country(),             'state'      => WC()->customer->get_shipping_state(),             'postcode'   => WC()->customer->get_shipping_postcode(),             'city'       => WC()->customer->get_shipping_city(),             'address'    => WC()->customer->get_shipping_address(),             'address_2'  => WC()->customer->get_shipping_address_2()         )     ); } if ( $  sr_package_items ) {     $  packages[] = array(         'contents'        => $  sr_package_items,         'contents_cost'   => array_sum( wp_list_pluck( $  sr_package_items, 'line_total' ) ),         'applied_coupons' => WC()->cart->get_applied_coupons(),         'user'            => array(              'ID' => get_current_user_id(),         ),         'destination'    => array(             'country'    => WC()->customer->get_shipping_country(),             'state'      => WC()->customer->get_shipping_state(),             'postcode'   => WC()->customer->get_shipping_postcode(),             'city'       => WC()->customer->get_shipping_city(),             'address'    => WC()->customer->get_shipping_address(),             'address_2'  => WC()->customer->get_shipping_address_2()         )     ); } return $  packages;     } add_filter( 'woocommerce_cart_shipping_packages', 'custom_split_shipping_packages_shipping_class' ); 

I want shipping for sr-box to restrict to UK only.

Can I restrict a Certification Authority to signing certain device/application?

Basically another administrator wants a subordinate CA certificate for their fancy appliance. How do I restrict the subordinate CA certificate issued to them only able to issuing for their usages and not allowing them to issue certificate that are used else where.

Having subordinate CA that is not under control is pretty risky, I need to make sure that the sub CA will not cause damange to the PKI system.

Is there some policy that I could set in the Sub CA for the restriction ?

Can we restrict Users from accessing Office 365 from certain IP address

we have office 365 tenant and our team over in india actively uses that for day to day stuff. But now we only want to allow users to access Office 365 from there office network. can we do that in Office 365.

When users login from other IP address other than office network it would simply block the access.

unable to restrict google drive and Google docs access by using Symantec Bluecoat proxy when system in public network. How to fix this?

We have policy related to YouTube and google docs blocking.

but,unable to restrict google drive and Google docs access by using Symantec Bluecoat proxy when system in public network.

or how we can meet this requirement.