## MLS API (Extenal API) images directly display on website, it gives error of 403 forbidden

Images work well before few days but now it’s getting an error of 403 forbidden. How to solve this issue, make sure it’s external images path

## Forbidden Sequence Dynamic Programming

Given a finite set $$\Omega$$, I have the following problem. Say there is a list of forbidden subsequences $$F \subset \Omega \cup \Omega^2 \cup \Omega^3 \dots \Omega^\infty$$, while we do not know the contents of list before hand, we can make a query about any sequence $$S \in \Omega^i$$ to see if $$\exists f \in F, f \subseteq S$$. I want to construct a sequence $$S \in \Omega^n$$ such that $$f \not \subseteq S, \forall f \in F$$.

I want to construct all the sequences $$S \in \Omega^n$$ such that $$f \not \subset S, \forall f \in F$$.

The approach I thought would be best is to use dynamic programming. We iteratively construct valid sets $$V_k := \{S \in \Omega_k: f \not \subset S ,\forall f \in F, |f|< k\}$$, by requiring each subsequence of $$s \in V_1 \cup \dots V_{k-1}, \forall s \subsetneq S$$, and then remove all $$S \in F$$ with queries. My question is, what’s the most efficient way to construct $$V_k$$? One simple way would be to take $$V_{k-1}$$ and then try adding each element in $$\Omega$$ at the end, and then do some extra queries, but is there some better way?

Additionally, are there elegant ways to use incomplete valid sets $$I_k \subseteq V_k$$, where if $$I_{k+1} := \{S \in \Omega^{k+1} \setminus F: s \in I^1 \cup \dots I^k, \forall s \subsetneq S\}$$ is empty, we can try to retroactively expand everything without mostly starting from scratch?

## Sampling a uniform distribution of fixed size strings containing no forbidden substrings

Given a list of “forbidden” words (substrings), an alphabet, and a desired output string length, how would I efficiently sample output strings containing no forbidden word?

For short output strings with few forbidden words, I would use simple rejection sampling. Pick a string (uniformly) with the specified alphabet and length, return that string if it contains no element of the forbidden list, try again otherwise.

If I use that algorithm for output lengths several times larger than the typical forbidden word, then the probability of rejection will be higher. (Most words are 2 or 3 characters long.)

Assume the requested output length is too long to enumerate and store every possible value. My alphabet size would be 16 to 36 characters, but solutions to large alphabets would be interesting to think about. (In which case I would call these things random sentences, forbidden n-grams, and dictionary words.)

My forbidden word list will have one hundred to one thousand strings. I would like to avoid solutions requiring expensive precomputation or lots of memory.

My first idea was to try to build a random string incrementally, in contrast to the all-or-nothing approach of straightforward rejection sampling. I doubt that my algorithm produces each possible output with equal probability.

The algorithm idea follows:

1. Initialize a char buffer long enough to fit outlen characters.
2. Pick a random letter of the alphabet and append it to the buffer.
3. If the buffer ends with a forbidden word of length k, then remove the last k letters from the char buffer and go to 2.
4. Otherwise, go to 2 if the buffer has less than outlen characters.
5. Return the contents of the buffer if it is full.

Step 3 serves to rewind the algorithm, returning the char buffer to a previous legal state.

I understand that clearing the whole buffer in step 3 definitely would produce uniform output just like the straightforward rejection sampling method. However, the average number of rejections before the first valid output is generated will be the same.

I’ve gotten stuck trying to determine if my proposed algorithm is uniform. I have had no luck finding alternative algorithms either. I haven’t yet looked at how this algorithm’s performance would compare to basic rejection sampling.

## Nginx 403 Forbidden error on a simple conf file

I’ve got a new Ubuntu 18.04 droplet on DO. Just installed Nginx and Ufw (which is disabled for now) on it. I’ve this conf file inside the /etc/nginx/conf.d folder.

server {     listen 80 ;     listen [::]:80 ;          root /var/www/2;         index index.html index.htm index.nginx-debian.html;          server_name 2.hotelbobbygg.xyz;          location / {                 try_files $uri$  uri/ =404;         } } 

I’ve also tried commenting out the 3rd line from last, i.e. try_files line. But it still behaves the same.

Pls help what is preventing me to access the index.html lying inside /var/www/2 folder.

## Powershell SharePoint 2016 csom 403 forbidden error

So new to CSOM and wanting to know if I am coding something wrong or where I need to look to resolve this issue. Or even if there is a SharePoint 2016 security setting that needs to be enabled for CSOM to work.

Also note, authentication is via Claims Authentication on the site it doesn’t work on.

Thanks!

# code

Add-Type -Path 'C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\ISAPI\Microsoft.SharePoint.Client.Runtime.dll' Add-Type -Path 'C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\ISAPI\Microsoft.SharePoint.Client.dll' $SharePointSite = 'https://Sharepointsite/sites/sitename'$  SharePointGroup = 'Test Group' $Creds = Get-Credential$  SPContext = New-Object Microsoft.SharePoint.Client.ClientContext("$SharePointSite")$  SPContext.Credentials = $Creds$  SPGroups=$SPContext.Web.SiteGroups$  SPContext.Load($spGroups)$  SPGroups=$SPGroups.GetByName("$  SharePointGroup") $SPContext.Load($  SPGroups)         $SPContext.ExecuteQuery()$  SPGroups.Title 

On my test side which is http://sharepointsite/site/testsite it works fine and finds the group.

On the root of the test site, https://sharepointsite/ it works and returns no group found.

When I test to an https://sharepointsite2 or https://sharepointsite2/site/testsite I get “403 Forbidden” But I have full access to sharepointsite2 root, sites, and central admin.

## 403 FORBIDDEN code posting to list

I am trying to post to a list with a custom form. Each time I try to submit my for the console prints out a “403 FORBIDDEN” error. I have Site Collection Admin rights for the entire site. Here is my code:

<body> 

Onboard Date:
Name:
Position:

No Yes

$(function () { bindButtonClick(); }); function bindButtonClick() {$ (“#btnSubmit”).on(“click”, function () { addListItem(); }); }

function addListItem() { var title = $(“#txtTitle”).val(); var position=$ (“#position”).val(); var date = $(“#datePicker”).val(); var oCheck =$ (“#choiceO”).val();

var fullUrl = "site/_api/web/lists/GetByTitle('FormDemo')/items";  $.ajax({ url: fullUrl, type: "POST", data: JSON.stringify({ '__metadata': { 'type': 'SP.Data.FormDemoListItem' }, 'Title': title, 'Position': position, 'OnboardDate': date, 'O': oCheck }), headers: { "accept": "application/json;odata=verbose", "content-type": "application/json;odata=verbose", "X-RequestDigest":$  ("#__REQUESTDIGEST").val()     },     success: onQuerySucceeded,     error: onQueryFailed }); 

}

function onQuerySucceeded(sender, args) { \$ (“#divResult”).html(“Item successfully added!”); }

## Pen test results for web application include a file from a forbidden directory that is not even used or referenced

In a recent pen test of a web application one of the issues found was a ‘backup file’. This was a javascript file that was renamed to filename.js1 when an updated version of filename.js was uploaded.

The ‘backup file’ lives in a directory with forbidden listing and is not referenced or used anywhere in the application.

How did they find this file?

## Error: “Forbidden” while accessing cross site lists using REST API in SPD 2013 workflows

I am not able to access the cross site lists using REST API in SharePoint Designer 2013 Workflow. I am making a call using action “Call HTTP Web Service”. I am facing the error in responseCode variable like “Forbidden”.

## 403 Forbidden Error Apache2 Ubuntu (Tried everything and all solutions I’ve ready.)

I know that this has been posted about A TON, but I have spent the last day scouring through answers, trying everything and nothing is working. I’ve changed permissions, I’ve looked into the Apache2 logs, I’ve altered configuration files, and I’m still getting the 403 forbidden error. Here are the apache2. My html files are in /var/www/html

I’m not completely sure, but I do recall troubles starting after trying to create user directories using: sudo a2enmod userdir

In side the apache error logs, the only thing on there that could be leading to something is this:

(13)Permission denied: [client myip] AH00035: access to  /folder/data/index.html denied (filesystem path  '/var/www/html/folder/data/index.html') because search permissions are  missing on a component of the path 

In my /etc/apache2/sites-available/000-default.conf, I added the following at the very end:

<Directory /var/www/html> AllowOverride All </Directory> 

In my apache2.conf I have the following:

<Directory />         Options FollowSymLinks         AllowOverride None         Require all denied </Directory>  <Directory /usr/share>         AllowOverride None         Require all granted </Directory>  <Directory /var/www/>         Options Indexes FollowSymLinks         AllowOverride ALL         Require all granted </Directory>  <Directory /var/www/html>         Options Indexes FollowSymLinks         AllowOverride ALL         Require all granted </Directory>  Again, I'm VERY sorry that I needed to make this thread, but I don't want to continue to copy and paste solutions that could do more harm than good. 

## App Step Forbidden error message – updating permissions group SP Designer 2013

When I try to run a Designer 2013 workflow with an App Step, I get the following results from my log:

7/25/2019 4:20 PM HRO ID: i:0#.f|membership|bob@bob.gov 7/25/2019 4:20 PM {“__metadata”:{“type”:”SP.User”},”LoginName”:”i:0#.f|membership|bob@bob.gov”} 7/25/2019 4:20 PM ***User Add Response Code: Forbidden

I have configured my site to allow App Steps – I can create them in my Designer workflows and publish them successfully. I know the URL I’m passing the REST call is correct because if I paste the URL directly into my browser, I get a successful result showing me the actual members of the permissions group I’m trying to update.

What should I be looking at in configurations to remedy this?