문제

사이트의 컨트롤을 통해 Page_Load에서 SPWEB를 만들려고합니다. 이 페이지의 보안 유효성 검사가 유효하지 않습니다 "오류가 발생합니다.

oputivent-method에서 켜져 있고 runwitheLevatedPrivileagues 이전에 켜져 있고 직접 켜져 있고 척추 틸리션을 시도했습니다.

내 제어의 ASCX에 FormDigest 컨트롤을 배치했습니다. MasterPage는 시애틀이며 FormDigestPlceHolder 및 Control을 포함합니다.

팜 계좌가있는 dev-system에서 작동하지만 통합 시스템에는 작동하지 않습니다. 나는 SP2013에있다.

모든 제안?

[업데이트 2] 확인 upde 1의 코드는 실제 문제가 아니 었습니다. 다음 줄에서 실제 문제가 발생했습니다.

Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "CreateMeetingRepost", "document.forms[0].submit();", true);
.

PAGE_LOAD 에서이 코드를 등록하여 사이트를 제출하여 사이트를 제출하십시오. 그러나 포스트 백 발생과 제어가 완전히로드 된 후 페이지가 다른 곳에서 보안 유효성 검사 오류가 발생합니다 (내 코드가 아님). 어떤 제안?

내가하고 싶은 것은 하위 사이트를 만드는 것입니다. RootWeb와 사이트에서 AllowUnsafeupdate를 시도했지만 작동하지 않았습니다. SharePoint는 ContentType을 새 웹에 복사하는 동안 InnerException을 throw합니다.

[Update1 - 문제가 아닙니다] 일부 코드 - MeetingManager.CreateMeetingAndFillURL은 하위 사이트를 생성합니다

SPSecurity.RunWithElevatedPrivileges(() =>
            {
                using (SPSite elevatedSite = new SPSite(SPContext.Current.Site.ID))
                {
                    using (SPLongOperation operation = new SPLongOperation(this.Page))
                    {
                        operation.LeadingHTML = "Meeting wird erstellt";
                        operation.Begin();
                        MeetingManager.CreateMeetingAndFillUrl(elevatedSite, currentMeeting);

                        try
                        {
                            operation.End(currentMeeting.Url);
                        }
                        catch (ThreadAbortException)
                        {
                            // This exception is thrown because the SPLongOperation.End
                            // calls a Response.End internally
                            // see: http://dotnetfollower.com/wordpress/2011/08/sharepoint-how-to-use-splongoperation/
                        }
                    }
                }
            });
.

도움이 되었습니까?

해결책

I found the problem. All the code is correct but there is an error in March 2013 PU. The FormDigest is set invalid and when doing a post the error occures. This is a real bad error.

http://nikpatel.net/2013/09/06/sharepoint-march-2013-public-update-invalid-formdigest-client-svc-processquery-403-forbidden/

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top