[Congressional Bills 115th Congress]
[From the U.S. Government Publishing Office]
[S. 2158 Introduced in Senate (IS)]

<DOC>






115th CONGRESS
  1st Session
                                S. 2158

 To amend the Foreign Intelligence Surveillance Act of 1978 to clarify 
 and improve the procedures and accountability for authorizing certain 
acquisitions of foreign intelligence, to extend title VII of such Act, 
 to ensure that the barriers to sharing critical foreign intelligence 
  among the intelligence community that existed before September 11, 
            2001, are not reimposed, and for other purposes.


_______________________________________________________________________


                   IN THE SENATE OF THE UNITED STATES

                           November 16, 2017

  Mr. Lee (for himself and Mr. Leahy) introduced the following bill; 
  which was read twice and referred to the Committee on the Judiciary

_______________________________________________________________________

                                 A BILL


 
 To amend the Foreign Intelligence Surveillance Act of 1978 to clarify 
 and improve the procedures and accountability for authorizing certain 
acquisitions of foreign intelligence, to extend title VII of such Act, 
 to ensure that the barriers to sharing critical foreign intelligence 
  among the intelligence community that existed before September 11, 
            2001, are not reimposed, and for other purposes.

    Be it enacted by the Senate and House of Representatives of the 
United States of America in Congress assembled,

SECTION 1. SHORT TITLE; TABLE OF CONTENTS.

    (a) Short Title.--This Act may be cited as the ``Uniting and 
Strengthening American Liberty Act of 2017'' or the ``USA Liberty Act 
of 2017''.
    (b) Table of Contents.--The table of contents for this Act is as 
follows:

Sec. 1. Short title; table of contents.
Sec. 2. Amendments to the Foreign Intelligence Surveillance Act of 
                            1978.
     TITLE I--FOREIGN INTELLIGENCE SURVEILLANCE AND ACCOUNTABILITY

Sec. 101. Court orders and protection of incidentally collected United 
                            States person communications.
Sec. 102. Attorney General approval and additional protection of 
                            incidentally collected United States person 
                            communications.
Sec. 103. Limitation on collection and improvements to targeting 
                            procedures and minimization procedures.
Sec. 104. Publication of minimization procedures under section 702.
Sec. 105. Appointment of amicus curiae for annual certifications.
Sec. 106. Increased accountability on incidentally collected 
                            communications.
Sec. 107. Semiannual reports on certain queries by Federal Bureau of 
                            Investigation.
Sec. 108. Additional reporting requirements.
Sec. 109. Application of certain amendments.
Sec. 110. Sense of Congress on purpose of section 702 and respecting 
                            foreign nationals.
   TITLE II--SAFEGUARDS AND OVERSIGHT OF PRIVACY AND CIVIL LIBERTIES

Sec. 201. Limitation on retention of certain data.
Sec. 202. Improvements to Privacy and Civil Liberties Oversight Board.
Sec. 203. Privacy and civil liberties officers.
Sec. 204. Whistleblower protections for contractors of the intelligence 
                            community.
TITLE III--EXTENSION OF AUTHORITIES, INCREASED PENALTIES, REPORTS, AND 
                             OTHER MATTERS

Sec. 301. Extension of title VII of FISA; effective dates.
Sec. 302. Increased penalty for unauthorized removal and retention of 
                            classified documents or material.
Sec. 303. Rule of construction regarding criminal penalties for 
                            unauthorized use of information acquired 
                            under section 702 and unauthorized 
                            disclosure of United States person 
                            information.
Sec. 304. Comptroller General study on unauthorized disclosures and the 
                            classification system.
Sec. 305. Sense of Congress on information sharing among intelligence 
                            community to protect national security.
Sec. 306. Sense of Congress on combating terrorism.
Sec. 307. Technical amendments and amendments to improve procedures of 
                            the Foreign Intelligence Surveillance Court 
                            of Review.
Sec. 308. Severability.
Sec. 309. Rule of construction.

SEC. 2. AMENDMENTS TO THE FOREIGN INTELLIGENCE SURVEILLANCE ACT OF 
              1978.

    Except as otherwise expressly provided, whenever in this Act an 
amendment or repeal is expressed in terms of an amendment to, or a 
repeal of, a section or other provision, the reference shall be 
considered to be made to a section or other provision of the Foreign 
Intelligence Surveillance Act of 1978 (50 U.S.C. 1801 et seq.).

     TITLE I--FOREIGN INTELLIGENCE SURVEILLANCE AND ACCOUNTABILITY

SEC. 101. COURT ORDERS AND PROTECTION OF INCIDENTALLY COLLECTED UNITED 
              STATES PERSON COMMUNICATIONS.

    (a) In General.--Section 702 (50 U.S.C. 1881a) is amended--
            (1) by redesignating subsections (j), (k), and (l) as 
        subsections (k), (l), and (m), respectively; and
            (2) by inserting after subsection (i) the following:
    ``(j) Requirements for Access and Dissemination of Collections of 
Communications.--
            ``(1) Court orders.--
                    ``(A) In general.--Except as provided under 
                paragraph (3), in response to a query relating to a 
                United States person or a person reasonably believed to 
                be located in the United States, the contents of 
                queried communications acquired under subsection (a) 
                may be accessed or disseminated only if--
                            ``(i) the Attorney General submits to the 
                        Foreign Intelligence Surveillance Court an 
                        application that demonstrates that--
                                    ``(I) there is probable cause to 
                                believe that--
                                            ``(aa) such contents 
                                        provide evidence of a crime 
                                        specified in section 2516 of 
                                        title 18, United States Code; 
                                        or
                                            ``(bb) the individual is an 
                                        agent of a foreign power; and
                                    ``(II) any use of such 
                                communications pursuant to section 706 
                                will be carried out in accordance with 
                                such section; and
                            ``(ii) a judge of the Foreign Intelligence 
                        Surveillance Court reviews and approves such 
                        application under subparagraph (B).
                    ``(B) Order.--
                            ``(i) Approval.--Upon an application made 
                        under subparagraph (A), the Foreign 
                        Intelligence Surveillance Court shall enter an 
                        order as requested or as modified by the Court 
                        approving the access or dissemination of 
                        contents of communications covered by the 
                        application if the Court determines that, based 
                        on an independent review--
                                    ``(I) the application contains all 
                                information required under subparagraph 
                                (A);
                                    ``(II) on the basis of the facts in 
                                the application, there is probable 
                                cause to believe that--
                                            ``(aa) such contents 
                                        provide evidence of a crime 
                                        specified in section 2516 of 
                                        title 18, United States Code; 
                                        or
                                            ``(bb) the person 
                                        identified by the queried term 
                                        is an agent of a foreign power; 
                                        and
                                    ``(III) the minimization procedures 
                                adopted pursuant to subsection (e) will 
                                ensure compliance with subparagraph 
                                (A)(i)(II).
                            ``(ii) Review.--A denial of an application 
                        submitted under subparagraph (A) may be 
                        reviewed as provided in section 103.
            ``(2) Expeditious consideration.--Any application submitted 
        under paragraph (1)(A) shall be considered by the Foreign 
        Intelligence Surveillance Court expeditiously and without 
        delay.
            ``(3) Exceptions.--The requirement for an order pursuant to 
        paragraph (1) shall not apply to accessing or disseminating 
        communications acquired under subsection (a) if--
                    ``(A) the Attorney General determines that the 
                person identified by the queried term is the subject of 
                an order based upon a finding of probable cause, or 
                emergency authorization, that authorizes electronic 
                surveillance or physical search under this Act or title 
                18, United States Code (other than such emergency 
                authorizations under title IV of this Act or section 
                3125 of title 18, United States Code);
                    ``(B) the Attorney General--
                            ``(i) reasonably determines that an 
                        emergency situation requires the accessing or 
                        dissemination of the communications before an 
                        order pursuant to paragraph (1) authorizing 
                        such access or dissemination can with due 
                        diligence be obtained;
                            ``(ii) reasonably believes that the factual 
                        basis for the issuance of such an order exists; 
                        and
                            ``(iii) with respect to the access or 
                        dissemination of the contents of such 
                        communications--
                                    ``(I) informs the Court at the time 
                                the Attorney General requires the 
                                emergency access or dissemination that 
                                the decision has been made to employ 
                                the authority under this paragraph; and
                                    ``(II) may not use the contents of 
                                such communications pursuant to section 
                                706 if the Court finds that the 
                                determination by the Attorney General 
                                with respect to the emergency situation 
                                was not appropriate; or
                    ``(C) there is consent provided in accordance with 
                paragraph (12).''.
    (b) Technical and Conforming Amendment.--Section 404(b)(4) of the 
Foreign Intelligence Surveillance Act of 1978 Amendments Act of 2008 
(50 U.S.C. 1801 note) is amended by striking ``702(l)'' each place it 
appears and inserting ``702(m)''.

SEC. 102. ATTORNEY GENERAL APPROVAL AND ADDITIONAL PROTECTION OF 
              INCIDENTALLY COLLECTED UNITED STATES PERSON 
              COMMUNICATIONS.

    Subsection (j) of section 702 (50 U.S.C. 1881a), as added by 
section 101, is amended by inserting after paragraph (3) the following:
            ``(4) Relevance and approval to access noncontents 
        information.--Except as provided under paragraph (5), in 
        response to a query relating to a United States person or a 
        person reasonably believed to be located in the United States, 
        the information of communications acquired under subsection (a) 
        relating to dialing, routing, addressing, or signaling 
        information that is not content and could otherwise be lawfully 
        obtained under title IV of this Act may be accessed or 
        disseminated only--
                    ``(A) with the approval of the Attorney General;
                    ``(B) if such information is relevant to an 
                authorized investigation or assessment and is not 
                sought solely on the basis of activities protected by 
                the First Amendment to the Constitution of the United 
                States;
                    ``(C) if an order based on probable cause would not 
                be required by law to obtain such information if 
                requested as part of an investigation of a Federal 
                crime; and
                    ``(D) if any use of such communications pursuant to 
                section 706 will be carried out in accordance with such 
                section.
            ``(5) Exceptions.--The requirement for approval of the 
        Attorney General under paragraph (4)(A) shall not apply to 
        accessing or disseminating information of communications 
        acquired under subsection (a) relating to dialing, routing, 
        addressing, or signaling information that is not content and 
        could otherwise be lawfully obtained under title IV of this Act 
        if--
                    ``(A) the Attorney General determines that the 
                person identified by the queried term is the subject of 
                an order based upon a finding of probable cause, or 
                emergency authorization, that authorizes electronic 
                surveillance or physical search under this Act or title 
                18, United States Code (other than such emergency 
                authorizations under title IV of this Act or section 
                3125 of title 18, United States Code);
                    ``(B) a supervisory determination is obtained 
                that--
                            ``(i) reasonably determines that an 
                        emergency situation requires the accessing or 
                        dissemination of the information of 
                        communications before the approval of the 
                        Attorney General under paragraph (4)(A) can 
                        with due diligence be obtained;
                            ``(ii) reasonably believes that the factual 
                        basis for the approval of the Attorney General 
                        under paragraph (4)(A) exists; and
                            ``(iii) with respect to the access or 
                        dissemination of such information of 
                        communications--
                                    ``(I) informs the Attorney General 
                                at the time the supervisor requires the 
                                emergency access or dissemination that 
                                the decision has been made to employ 
                                the authority under this subparagraph; 
                                and
                                    ``(II) may not use such information 
                                of communications pursuant to section 
                                706 if the Attorney General finds that 
                                the determination by the supervisor 
                                with respect to the emergency situation 
                                was not appropriate; or
                    ``(C) there is consent provided in accordance with 
                paragraph (12).
            ``(6) Due diligence.--A determination of whether the person 
        identified by the queried term is a United States person or a 
        person reasonably believed to be located in the United States 
        under paragraph (1) or (4) shall be made based on the totality 
        of the circumstances, including by, to the extent practicable, 
        ensuring that any conflicting information regarding whether the 
        person is a United States person or is reasonably believed to 
        be located outside the United States is resolved before making 
        such determination. If there is insufficient information 
        available to make a determination, the person identified by the 
        queried term shall be considered a United States person or 
        person reasonably believed to be located in the United States 
        for purposes of paragraphs (1) and (4).
            ``(7) Limitation on electronic surveillance of united 
        states persons.--If the Attorney General determines that it is 
        necessary to conduct electronic surveillance on a known United 
        States person whose communications have been acquired under 
        subsection (a), the Attorney General may only conduct such 
        electronic surveillance using authority provided under other 
        provisions of law.
            ``(8) Simultaneous query of fbi databases.--Except as 
        otherwise provided by law or applicable minimization 
        procedures, the Director of the Federal Bureau of Investigation 
        shall ensure that all available investigative or intelligence 
        databases of the Federal Bureau of Investigation are 
        simultaneously queried when the Federal Bureau of Investigation 
        properly uses an information system of the Federal Bureau of 
        Investigation to determine whether information exists in such a 
        database.
            ``(9) Delegation.--The Attorney General shall delegate the 
        authority under this subsection to the fewest number of 
        officials that the Attorney General determines practicable.
            ``(10) Retention of auditable records.--
                    ``(A) Records.--The Attorney General shall retain 
                records of queries of a collection of communications 
                acquired under subsection (a). The heads of elements of 
                the intelligence community that are not components of 
                the Department of Justice shall retain records of 
                queries of a collection of communications acquired 
                under subsection (a) that use a term identifying a 
                United States person or a person located in the United 
                States.
                    ``(B) Requirements.--Records retained under 
                subparagraph (A) shall--
                            ``(i) include queries for not less than 5 
                        years after the date on which the query is 
                        made; and
                            ``(ii) be maintained in a manner that is 
                        auditable and available for congressional 
                        oversight.
            ``(11) Compliance and maintenance.--The requirements of 
        this subsection do not apply with respect to queries made for 
        the purpose of--
                    ``(A) submitting to Congress information required 
                by this Act or otherwise ensuring compliance with the 
                requirements of this section; or
                    ``(B) performing maintenance or testing of 
                information systems.
            ``(12) Consent.--The requirements of this subsection do not 
        apply with respect to--
                    ``(A) queries made using a term identifying a 
                person who is a party to the communications acquired 
                under subsection (a), or a person who otherwise has 
                lawful authority to provide consent, and who consents 
                to such queries; or
                    ``(B) the accessing or the dissemination of the 
                contents or information of communications acquired 
                under subsection (a) of a person who is a party to the 
                communications, or a person who otherwise has lawful 
                authority to provide consent, and who consents to such 
                access or dissemination.
            ``(13) Query purposes.--The contents of communications 
        acquired under subsection (a) and the information relating to 
        the dialing, routing, addressing, or signaling information of 
        such communications may only be queried if the query is 
        reasonably designed to return foreign intelligence information 
        or evidence of a crime.''.

SEC. 103. LIMITATION ON COLLECTION AND IMPROVEMENTS TO TARGETING 
              PROCEDURES AND MINIMIZATION PROCEDURES.

    (a) Targeting Procedures; Limitation on Collection.--Section 702(d) 
(50 U.S.C. 1881a(d)) is amended--
            (1) in paragraph (1), by striking ``The Attorney General'' 
        and inserting ``In accordance with paragraphs (3) and (4), the 
        Attorney General''; and
            (2) by adding at the end the following new paragraphs:
            ``(3) Due diligence.--The procedures adopted in accordance 
        with paragraph (1) shall require due diligence in determining 
        whether a person targeted is a non-United States person 
        reasonably believed to be located outside the United States 
        by--
                    ``(A) making the determination based on the 
                totality of the circumstances, including by, to the 
                extent practicable, ensuring that any conflicting 
                information regarding whether the person is reasonably 
                believed to be located outside the United States or is 
                a United States person is resolved before making such 
                determination;
                    ``(B) documenting the processes used for 
                determinations described in subparagraph (A); and
                    ``(C) documenting the rationale for why targeting 
                such person will result in the acquisition of foreign 
                intelligence information authorized by subsection (a).
            ``(4) Limitation.--
                    ``(A) In general.--The procedures adopted in 
                accordance with paragraph (1) shall require that the 
                targeting of a person is limited to communications to 
                or from the targeted person.
                    ``(B) Annual report.--On an annual basis, the 
                Attorney General shall submit to the congressional 
                intelligence committees and the Committees on the 
                Judiciary of the House of Representatives and the 
                Senate a report on--
                            ``(i) any difficulty relating to the 
                        limitation under subparagraph (A); and
                            ``(ii) the technical feasibility of 
                        ensuring that the handling of communications 
                        acquired under subsection (a) with respect to 
                        incidentally collected United States person 
                        information complies with the minimization 
                        procedures adopted under subsection (e).''.
    (b) Minimization Procedures.--Section 702(e) (50 U.S.C. 1881a(e)) 
is amended--
            (1) in paragraph (1), by inserting ``, and the requirements 
        of this subsection'' before the period at the end; and
            (2) by adding at the end the following new paragraph:
            ``(3) Requests to unmask information.--The procedures 
        adopted under paragraph (1) shall include specific procedures 
        adopted by the Attorney General for elements of the 
        intelligence community to submit requests to unmask information 
        in disseminated intelligence reports. Such specific procedures 
        shall--
                    ``(A) require the documentation of the requesting 
                individual that such request is for legitimate reasons 
                authorized pursuant to paragraph (1); and
                    ``(B) require the retention of the records of each 
                request, including--
                            ``(i) a copy of the request;
                            ``(ii) the name and position of the 
                        individual who is making the request; and
                            ``(iii) if the request is approved, the 
                        name and position of the individual who 
                        approved the request and the date of the 
                        approval.''.
    (c) Unmask Defined.--Section 701(b) (50 U.S.C. 1881(b)) is amended 
by adding at the end the following new paragraph:
            ``(6) Unmask.--The term `unmask' means, with respect to a 
        disseminated intelligence report containing a reference to a 
        United States person that does not identify that person 
        (including by name or title), to disseminate the identity of 
        the United States person, including the name or title of the 
        person.''.
    (d) Consistent Requirements To Retain Records on Requests To Unmask 
Information.--The Foreign Intelligence Surveillance Act of 1978 (50 
U.S.C. 1801 et seq.) is amended as follows:
            (1) In section 101(h) (50 U.S.C. 1801(h))--
                    (A) in paragraph (3), by striking ``; and'' and 
                inserting a semicolon;
                    (B) in paragraph (4), by striking the period at the 
                end and inserting ``; and''; and
                    (C) by adding at the end the following new 
                paragraph:
            ``(5) specific procedures as described in section 
        702(e)(3).''.
            (2) In section 301(4) (50 U.S.C. 1821(4))--
                    (A) in subparagraph (C), by striking ``; and'' and 
                inserting a semicolon;
                    (B) in subparagraph (D), by striking the period at 
                the end and inserting ``; and''; and
                    (C) by adding at the end the following new 
                subparagraph:
                    ``(E) specific procedures as described in section 
                702(e)(3).''.
            (3) In section 402(h) (50 U.S.C. 1842(h))--
                    (A) by redesignating paragraph (2) as paragraph 
                (3); and
                    (B) by inserting after paragraph (1) the following 
                new paragraph (2):
            ``(2) Requests for nonpublicly available information.--The 
        policies and procedures adopted under paragraph (1) shall 
        include specific procedures as described in section 
        702(e)(3).''.
            (4) In section 501(g)(2) (50 U.S.C. 1861(g)(2))--
                    (A) in subparagraph (B), by striking ``; and'' and 
                inserting a semicolon;
                    (B) in subparagraph (C), by striking the period at 
                the end and inserting ``; and''; and
                    (C) by adding at the end the following new 
                subparagraph:
                    ``(D) specific procedures as described in section 
                702(e)(3).''.
    (e) Report on Unmasking.--Not later than 90 days after the date of 
the enactment of this Act, the Director of National Intelligence shall 
submit to the Permanent Select Committee on Intelligence of the House 
of Representatives, the Select Committee on Intelligence of the Senate, 
and the Committees on the Judiciary of the House of Representatives and 
the Senate a report on the progress made by the Director with respect 
to--
            (1) ensuring that incidentally collected communications of 
        United States persons (as defined in section 101 of the Foreign 
        Intelligence Surveillance Act of 1978 (50 U.S.C. 1801)) are 
        properly masked if masking is necessary; and
            (2) implementing procedures for requests to unmask 
        information under section 702(e)(3) of such Act (50 U.S.C. 
        1881a(e)(3)), as added by subsection (c).

SEC. 104. PUBLICATION OF MINIMIZATION PROCEDURES UNDER SECTION 702.

    Section 702(e) (50 U.S.C. 1881a(e)), as amended by section 103, is 
further amended by adding at the end the following:
            ``(4) Publication.--The Director of National Intelligence, 
        in consultation with the Attorney General, shall--
                    ``(A) conduct a declassification review of any 
                minimization procedures adopted or amended in 
                accordance with paragraph (1); and
                    ``(B) consistent with such review, and not later 
                than 180 days after conducting such review, make such 
                minimization procedures publicly available to the 
                greatest extent practicable, which may be in redacted 
                form.''.

SEC. 105. APPOINTMENT OF AMICUS CURIAE FOR ANNUAL CERTIFICATIONS.

    Section 103(i) (50 U.S.C. 1803(i)(2)) is amended--
            (1) in paragraph (2)--
                    (A) in subparagraph (A), by striking ``; and'' and 
                inserting a semicolon;
                    (B) by redesignating subparagraph (B) as 
                subparagraph (C); and
                    (C) by inserting after subparagraph (A) the 
                following new subparagraph (B):
                    ``(B) shall appoint an individual who has been 
                designated under paragraph (1) to serve as amicus 
                curiae to assist such court in the review of a 
                certification under section 702(i), unless the court 
                issues a finding that such appointment is not 
                necessary; and''; and
            (2) in paragraphs (4) and (5), by striking ``paragraph 
        (2)(A)'' both places it appears and inserting ``subparagraph 
        (A) or (B) of paragraph (2)''.

SEC. 106. INCREASED ACCOUNTABILITY ON INCIDENTALLY COLLECTED 
              COMMUNICATIONS.

    Section 707 (50 U.S.C. 1881f) is amended by adding at the end the 
following new subsection:
    ``(c) Incidentally Collected Communications and Other 
Information.--Together with the semiannual report submitted under 
subsection (a), the Director of National Intelligence shall submit to 
the congressional committees specified in such subsection a report on 
incidentally collected communications and other information regarding 
United States persons under section 702. Each such report shall 
include, with respect to the 6-month period covered by the report, the 
following:
            ``(1) Except as provided by paragraph (2), the number, or a 
        good faith estimate, of communications of United States persons 
        acquired under subsection (a) of such section, including a 
        description of any efforts of the intelligence community to 
        ascertain such number or good faith estimate.
            ``(2) If the Director determines that the number, or a good 
        faith estimate, under paragraph (1) is not achievable, a 
        detailed explanation for why such number or good faith estimate 
        is not achievable.
            ``(3) The number of--
                    ``(A) United States persons whose information is 
                unmasked pursuant to the procedures adopted under 
                subsection (e)(3) of such section;
                    ``(B) requests made by an element of the 
                intelligence community, listed by each such element, to 
                unmask information pursuant to such subsection; and
                    ``(C) requests that resulted in the dissemination 
                of names, titles, or other identifiers potentially 
                associated with individuals pursuant to such 
                subsection, including the element of the intelligence 
                community and position of the individual making the 
                request.
            ``(4) The number of disseminations of communications 
        acquired under subsection (a) of section 702 to the Federal 
        Bureau of Investigation for cases unrelated to foreign 
        intelligence.
            ``(5) The number of instances in which evidence of a crime 
        unrelated to foreign intelligence that was identified in 
        communications acquired under subsection (a) of section 702 was 
        disseminated from the national security branch of the Bureau to 
        the criminal investigative division of the Bureau (or from such 
        successor branch to such successor division).
            ``(6) The number of individuals to whom the Attorney 
        General has delegated authority pursuant to subsection 
        (j)(2)(G) of section 702.''.

SEC. 107. SEMIANNUAL REPORTS ON CERTAIN QUERIES BY FEDERAL BUREAU OF 
              INVESTIGATION.

    Section 707 (50 U.S.C. 1881f), as amended by section 106, is 
further amended by adding at the end the following new subsection:
    ``(d) Semiannual FBI Reports.--Together with the semiannual report 
submitted under subsection (a), the Director of the Federal Bureau of 
Investigation shall submit to the congressional committees specified in 
such subsection, and make publicly available, a report containing, with 
respect to the period covered by the report--
            ``(1) the number of applications made by the Federal Bureau 
        of Investigation described in subsection (j)(1)(A) of section 
        702;
            ``(2) the number of such applications that were approved 
        and resulted in the contents of communications being accessed 
        or disseminated pursuant to such subsection; and
            ``(3) the number of Attorney General approvals made 
        pursuant to subsection (j)(4)(A) of such section.''.

SEC. 108. ADDITIONAL REPORTING REQUIREMENTS.

    (a) Electronic Surveillance.--Section 107 (50 U.S.C. 1807) is 
amended to read as follows:

``SEC. 107. REPORT OF ELECTRONIC SURVEILLANCE.

    ``(a) Annual Report.--In April of each year, the Attorney General 
shall transmit to the Administrative Office of the United States Courts 
and to Congress a report setting forth with respect to the preceding 
calendar year--
            ``(1) the total number of applications made for orders and 
        extensions of orders approving electronic surveillance under 
        this title;
            ``(2) the total number of such orders and extensions either 
        granted, modified, or denied; and
            ``(3) the total number of persons who were subject to 
        electronic surveillance conducted under an order or emergency 
        authorization under this title, rounded to the nearest 500, 
        including the number of such individuals who are United States 
        persons, reported to the nearest band of 500, starting with 0-
        499.
    ``(b) Form.--Each report under subsection (a) shall be submitted in 
unclassified form. Not later than 7 days after the date on which the 
Attorney General submits each such report, the Attorney General shall 
make the report publicly available.''.
    (b) Pen Registers and Trap and Trace Devices.--Section 406 (50 
U.S.C. 1846) is amended--
            (1) in subsection (b)--
                    (A) in paragraph (4), by striking ``; and'' and 
                inserting a semicolon;
                    (B) in paragraph (5), by striking the period at the 
                end and inserting ``; and''; and
                    (C) by adding at the end the following new 
                paragraph:
            ``(6) a good faith estimate of the total number of subjects 
        who were targeted by the installation and use of a pen register 
        or trap and trace device under an order or emergency 
        authorization issued under this title, rounded to the nearest 
        500, including--
                    ``(A) the number of such subjects who are United 
                States persons, reported to the nearest band of 500, 
                starting with 0-499; and
                    ``(B) of the number of United States persons 
                described in subparagraph (A), the number of persons 
                whose information acquired pursuant to such order was 
                reviewed or accessed by a Federal officer, employee, or 
                agent, reported to the nearest band of 500, starting 
                with 0-499.''; and
            (2) by adding at the end the following new subsection:
    ``(c) Each report under subsection (b) shall be submitted in 
unclassified form. Not later than 7 days after the date on which the 
Attorney General submits such a report, the Attorney General shall make 
such report publicly available.''.

SEC. 109. APPLICATION OF CERTAIN AMENDMENTS.

    The amendments made by sections 101, 102, and 103 of this Act shall 
apply with respect to applications, certifications, and procedures 
submitted to the Foreign Intelligence Surveillance Court on or after 
the date that is 120 days after the date of the enactment of this Act.

SEC. 110. SENSE OF CONGRESS ON PURPOSE OF SECTION 702 AND RESPECTING 
              FOREIGN NATIONALS.

    It is the sense of Congress that--
            (1) the acquisition of communications by the National 
        Security Agency under section 702 of the Foreign Intelligence 
        Surveillance Act (50 U.S.C. 1881a) should be conducted within 
        the bounds of treaties and agreements to which the United 
        States is a party, and there should be no targeting of non-
        United States persons for any unfounded discriminatory purpose 
        or for the purpose of affording a commercial competitive 
        advantage to companies and business sectors of the United 
        States; and
            (2) the authority to collect intelligence under such 
        section 702 is meant to shield the United States, and by 
        extension, the allies of the United States, from security 
        threats.

   TITLE II--SAFEGUARDS AND OVERSIGHT OF PRIVACY AND CIVIL LIBERTIES

SEC. 201. LIMITATION ON RETENTION OF CERTAIN DATA.

    Subsection (m) of section 702 (50 U.S.C. 1881a), as redesignated by 
section 101, is amended--
            (1) by redesignating paragraphs (2) and (3) as paragraphs 
        (3) and (4); and
            (2) by inserting after paragraph (1) the following new 
        paragraph (2):
            ``(2) Affidavit on deletion included in semiannual 
        assessment to fisc and congress.--Each semiannual assessment 
        under paragraph (1) shall include, with respect to the 6-month 
        period covered by the assessment, an affidavit by the Director 
        of the National Security Agency, without delegation, that 
        communications acquired under subsection (a) determined not to 
        contain foreign intelligence information, if any, were 
        deleted.''.

SEC. 202. IMPROVEMENTS TO PRIVACY AND CIVIL LIBERTIES OVERSIGHT BOARD.

    (a) Appointment of Staff.--Subsection (j) of section 1061 of the 
Intelligence Reform and Terrorism Prevention Act of 2004 (42 U.S.C. 
2000ee(j)) is amended--
            (1) by redesignating paragraphs (2) and (3) as paragraphs 
        (3) and (4), respectively; and
            (2) by inserting after paragraph (1) the following new 
        paragraph:
            ``(2) Appointment in absence of chairman.--If the position 
        of chairman of the Board is vacant, during the period of the 
        vacancy, the Board, at the direction of the unanimous vote of 
        the serving members of the Board, may exercise the authority of 
        the chairman under paragraph (1).''.
    (b) Meetings.--Subsection (f) of such section (42 U.S.C. 2000ee(f)) 
is amended--
            (1) by striking ``The Board shall'' and inserting ``The 
        Board'';
            (2) in paragraph (1) by striking ``make its'' and inserting 
        ``shall make its''; and
            (3) in paragraph (2)--
                    (A) by striking ``hold public'' and inserting 
                ``shall hold public''; and
                    (B) by inserting before the period at the end the 
                following: ``, but may, notwithstanding section 552b of 
                title 5, United States Code, meet or otherwise 
                communicate in any number to confer or deliberate in a 
                manner that is closed to the public''.
    (c) Report on Section 702 and Terrorism.--Not later than 1 year 
after the date on which the Privacy and Civil Liberties Oversight Board 
first achieves a quorum following the date of the enactment of this 
Act, the Board shall submit to the Committee on the Judiciary and the 
Permanent Select Committee on Intelligence of the House of 
Representatives and the Committee on the Judiciary and the Select 
Committee on Intelligence of the Senate a report assessing--
            (1) how communications acquired under section 702 of the 
        Foreign Intelligence Surveillance Act of 1978 (50 U.S.C. 1881a) 
        are used by the United States to prevent or defend against 
        terrorism;
            (2) whether technological challenges and changes in 
        technology affect the prevention of and defense against 
        terrorism, and how effectively the foreign intelligence 
        elements of the intelligence community (as defined in section 
        3(4) of the National Security Act of 1947 (50 U.S.C. 3003(4))) 
        have responded to those challenges; and
            (3) how privacy and civil liberties are affected by the 
        actions identified under paragraph (1) and the changes in 
        technology identified under paragraph (2), and whether race, 
        religion, political affiliation, or activities protected by the 
        First Amendment to the Constitution of the United States are 
        determinative in the targeting or querying decisions made 
        pursuant to such section 702.

SEC. 203. PRIVACY AND CIVIL LIBERTIES OFFICERS.

    (a) Codification of Certain Officers.--Section 1062(a) of the 
Intelligence Reform and Terrorism Prevention Act of 2004 (42 U.S.C. 
2000ee-1(a)) is amended in the matter preceding paragraph (1) by 
inserting ``, the Director of the National Security Agency, the 
Director of the Federal Bureau of Investigation'' after ``the Director 
of the Central Intelligence Agency''.
    (b) Annual Reports on Incidental Communications of United States 
Persons.--Paragraph (4)(A) of subsection (m) of section 702 (50 U.S.C. 
1881a), as redesignated by sections 101 and 201, is amended--
            (1) in clause (iii), by striking ``; and'' and inserting a 
        semicolon;
            (2) in clause (iv), by striking the period at the end and 
        inserting ``; and''; and
            (3) by adding at the end the following new clause:
                            ``(v) a review by the privacy and civil 
                        liberties officer of the element of 
                        incidentally collected communications of United 
                        States persons to assess compliance with the 
                        minimization procedures adopted under 
                        subsection (e) and the effect of this section 
                        on the privacy of United States persons.''.

SEC. 204. WHISTLEBLOWER PROTECTIONS FOR CONTRACTORS OF THE INTELLIGENCE 
              COMMUNITY.

    (a) Prohibited Personnel Practices in the Intelligence Community.--
Section 1104 of the National Security Act of 1947 (50 U.S.C. 3234) is 
amended--
            (1) in subsection (a)--
                    (A) by redesignating paragraphs (2) and (3) as 
                paragraphs (3) and (4), respectively;
                    (B) by inserting after paragraph (1) the following:
            ``(2) Contractor employee.--The term `contractor employee' 
        means an employee of a contractor, subcontractor, grantee, 
        subgrantee, or personal services contractor of a covered 
        intelligence community element.''; and
                    (C) in paragraph (4), as so redesignated, in the 
                matter preceding subparagraph (A) by inserting ``or a 
                contractor employee of a covered intelligence community 
                element'' after ``character)'';
            (2) by redesignating subsections (c) and (d) as subsections 
        (d) and (e), respectively;
            (3) by inserting after subsection (b) the following new 
        subsection (c):
    ``(c) Contractor Employees.--(1) A contractor employee or employee 
of a covered intelligence community element who has authority to take, 
direct others to take, recommend, or approve any personnel action, 
shall not, with respect to such authority, take or fail to take a 
personnel action with respect to any contractor employee as a reprisal 
for a lawful disclosure of information by the contractor employee to 
the Director of National Intelligence (or an employee designated by the 
Director of National Intelligence for such purpose), the Inspector 
General of the Intelligence Community, the head of the contracting 
agency (or an employee designated by the head of that agency for such 
purpose), the appropriate inspector general of the contracting agency, 
a congressional intelligence committee, or a member of a congressional 
intelligence committee, which the contractor employee reasonably 
believes evidences--
            ``(A) a violation of any Federal law, rule, or regulation 
        (including with respect to evidence of another employee or 
        contractor employee accessing or sharing classified information 
        without authorization); or
            ``(B) mismanagement, a gross waste of funds, an abuse of 
        authority, or a substantial and specific danger to public 
        health or safety.
    ``(2) A personnel action under paragraph (1) is prohibited even if 
the action is undertaken at the request of an officer or employee of 
the applicable covered intelligence community element, unless the 
request takes the form of a nondiscretionary directive and is within 
the authority of the officer or employee making the request.
    ``(3) A contractor employee may raise a violation of paragraph (1) 
in any proceeding to implement or challenge a personnel action 
described in such paragraph.'';
            (4) in subsection (b), by striking the heading and 
        inserting ``Agency Employees.--''; and
            (5) in subsection (e)(1), as redesignated by paragraph (2), 
        by inserting ``contractor employee,'' after ``any employee,''.
    (b) Federal Bureau of Investigation.--
            (1) In general.--Any contractor employee or employee of the 
        Federal Bureau of Investigation who has authority to take, 
        direct others to take, recommend, or approve any personnel 
        action, shall not, with respect to such authority, take or fail 
        to take a personnel action with respect to a contractor 
        employee as a reprisal for a disclosure of information--
                    (A) made--
                            (i) to a supervisor in the direct chain of 
                        command of the contractor employee, up to and 
                        including the Director of the Federal Bureau of 
                        Investigation;
                            (ii) to the Inspector General of the 
                        Department of Justice;
                            (iii) to the Office of Professional 
                        Responsibility of the Department of Justice;
                            (iv) to the Office of Professional 
                        Responsibility of the Federal Bureau of 
                        Investigation;
                            (v) to the Inspection Division of the 
                        Federal Bureau of Investigation;
                            (vi) as described in section 7211 of title 
                        5, United States Code;
                            (vii) to the Office of Special Counsel; or
                            (viii) to an employee designated by any 
                        officer, employee, office, or division 
                        described in clauses (i) through (vii) for the 
                        purpose of receiving such disclosures; and
                    (B) which the contractor employee reasonably 
                believes evidences--
                            (i) any violation of any law, rule, or 
                        regulation (including with respect to evidence 
                        of another employee or contractor employee 
                        accessing or sharing classified information 
                        without authorization); or
                            (ii) gross mismanagement, a gross waste of 
                        funds, an abuse of authority, or a substantial 
                        and specific danger to public health or safety.
            (2) Actions by request.--A personnel action under paragraph 
        (1) is prohibited even if the action is undertaken at the 
        request of an officer or employee of the Federal Bureau of 
        Investigation, unless the request takes the form of a 
        nondiscretionary directive and is within the authority of the 
        officer or employee making the request.
            (3) Violation.--A contractor employee may raise a violation 
        of paragraph (1) in any proceeding to implement or challenge a 
        personnel action described in such paragraph.
            (4) Regulations.--The Attorney General shall prescribe 
        regulations to ensure that a personnel action described in 
        paragraph (1) shall not be taken against a contractor employee 
        of the Bureau as a reprisal for any disclosure of information 
        described in such paragraph.
            (5) Enforcement.--The President shall provide for the 
        enforcement of this subsection in a manner consistent with 
        applicable provisions of sections 1214 and 1221 of title 5, 
        United States Code.
            (6) Definitions.--In this subsection:
                    (A) The term ``contractor employee'' means an 
                employee of a contractor, subcontractor, grantee, 
                subgrantee, or personal services contractor, of the 
                Federal Bureau of Investigation.
                    (B) The term ``personnel action'' means any action 
                described in clauses (i) through (x) of section 
                2302(a)(2)(A) of title 5, United States Code, with 
                respect to a contractor employee.
    (c) Retaliatory Revocation of Security Clearances and Access 
Determinations.--Section 3001(j) of the Intelligence Reform and 
Terrorism Prevention Act of 2004 (50 U.S.C. 3341(j)) is amended by 
adding at the end the following new paragraph:
            ``(8) Inclusion of contractor employees.--In this 
        subsection, the term `employee' includes an employee of a 
        contractor, subcontractor, grantee, subgrantee, or personal 
        services contractor, of an agency. With respect to such 
        employees, the term `employing agency' shall be deemed to be 
        the contracting agency.''.

TITLE III--EXTENSION OF AUTHORITIES, INCREASED PENALTIES, REPORTS, AND 
                             OTHER MATTERS

SEC. 301. EXTENSION OF TITLE VII OF FISA; EFFECTIVE DATES.

    (a) Extension.--Section 403(b) of the FISA Amendments Act of 2008 
(Public Law 110-261; 122 Stat. 2474) is amended--
            (1) in paragraph (1)--
                    (A) by striking ``December 31, 2017'' and inserting 
                ``September 30, 2023''; and
                    (B) by inserting ``and by the USA Liberty Act of 
                2017'' after ``section 101(a)''; and
            (2) in paragraph (2) in the matter preceding subparagraph 
        (A), by striking ``December 31, 2017'' and inserting 
        ``September 30, 2023''.
    (b) Conforming Amendments.--Section 404(b) of the FISA Amendments 
Act of 2008 (Public Law 110-261; 122 Stat. 2476) is amended--
            (1) in paragraph (1)--
                    (A) in the heading, by striking ``December 31, 
                2017'' and inserting ``September 30, 2023''; and
                    (B) by inserting ``and by the USA Liberty Act of 
                2017'' after ``section 101(a)'';
            (2) in paragraph (2), by inserting ``and by the USA Liberty 
        Act of 2017'' after ``section 101(a)''; and
            (3) in paragraph (4)--
                    (A) by inserting ``and amended by the USA Liberty 
                Act of 2017'' after ``as added by section 101(a)'' both 
                places it appears; and
                    (B) by inserting ``and by the USA Liberty Act of 
                2017'' after ``as amended by section 101(a)'' both 
                places it appears.
    (c) Effective Date of Amendments to FAA.--The amendments made to 
the FISA Amendments Act of 2008 (Public Law 110-261) by this section 
shall take effect on the earlier of the date of the enactment of this 
Act or December 31, 2017.

SEC. 302. INCREASED PENALTY FOR UNAUTHORIZED REMOVAL AND RETENTION OF 
              CLASSIFIED DOCUMENTS OR MATERIAL.

    Section 1924(a) of title 18, United States Code, is amended by 
striking ``one year'' and inserting ``5 years''.

SEC. 303. RULE OF CONSTRUCTION REGARDING CRIMINAL PENALTIES FOR 
              UNAUTHORIZED USE OF INFORMATION ACQUIRED UNDER SECTION 
              702 AND UNAUTHORIZED DISCLOSURE OF UNITED STATES PERSON 
              INFORMATION.

    Nothing in this Act or the amendments made by this Act may be 
construed to limit the application or effect of criminal penalties 
under section 552a(i) of title 5, United States Code, sections 1001, 
1030, and 1924 of title 18, United States Code, or any other relevant 
provision of law, with respect to offenses relating to the unauthorized 
access or use of information acquired under section 702 of the Foreign 
Intelligence Surveillance Act (50 U.S.C. 1881a) or the unauthorized 
disclosure of United States person information acquired under such 
section.

SEC. 304. COMPTROLLER GENERAL STUDY ON UNAUTHORIZED DISCLOSURES AND THE 
              CLASSIFICATION SYSTEM.

    (a) Study.--The Comptroller General of the United States shall 
conduct a study of the unauthorized disclosure of classified 
information and the classification system of the United States.
    (b) Matters Included.--The study under subsection (a) shall address 
the following:
            (1) Insider threat risks to the unauthorized disclosure of 
        classified information.
            (2) The effect of modern technology on the unauthorized 
        disclosure of classified information, including with respect 
        to--
                    (A) using cloud storage for classified information; 
                and
                    (B) any technological means to prevent or detect 
                such unauthorized disclosure.
            (3) The effect of overclassification on the unauthorized 
        disclosure of classified information.
            (4) Any ways to improve the classification system of the 
        United States, including with respect to changing the levels of 
        classification used in such system and to reduce 
        overclassification.
            (5) How to improve the authorized sharing of classified 
        information, including with respect to sensitive compartmented 
        information.
            (6) The value of polygraph tests in determining who is 
        authorized to access classified information.
            (7) Whether each element of the intelligence community (as 
        defined in section 3(4) of the National Security Act of 1947 
        (50 U.S.C. 3003(4)))--
                    (A) applies uniform standards in determining who is 
                authorized to access classified information; and
                    (B) provides proper training with respect to the 
                handling of classified information and the avoidance of 
                overclassification.
    (c) Cooperation.--The heads of the intelligence community shall 
provide to the Comptroller General information the Comptroller General 
determines necessary to carry out the study under subsection (a).
    (d) Report.--Not later than 180 days after the date of the 
enactment of this Act, the Comptroller General shall submit to the 
Committee on the Judiciary and the Permanent Select Committee on 
Intelligence of the House of Representatives and the Committee on the 
Judiciary and the Select Committee on Intelligence of the Senate a 
report containing the study under subsection (a).
    (e) Form.--The report under subsection (d) shall be submitted in 
unclassified form, but may include a classified annex.

SEC. 305. SENSE OF CONGRESS ON INFORMATION SHARING AMONG INTELLIGENCE 
              COMMUNITY TO PROTECT NATIONAL SECURITY.

    It is the sense of Congress that, in carrying out section 702 of 
the Foreign Intelligence Surveillance Act of 1978 (50 U.S.C. 1881a), as 
amended by this Act, the United States Government should ensure that 
the barriers, whether real or perceived, to sharing critical foreign 
intelligence among the intelligence community that existed before 
September 11, 2001, are not reimposed by sharing information vital to 
national security among the intelligence community in a manner that is 
consistent with such section, applicable provisions of law, and the 
Constitution of the United States.

SEC. 306. SENSE OF CONGRESS ON COMBATING TERRORISM.

    It is the sense of Congress that, consistent with the protection of 
sources and methods, when lawful and appropriate, the President should 
share information learned by acquiring communications under section 702 
of the Foreign Intelligence Surveillance Act (50 U.S.C. 1881a) with 
allies of the United States to prevent and defend against terrorism.

SEC. 307. TECHNICAL AMENDMENTS AND AMENDMENTS TO IMPROVE PROCEDURES OF 
              THE FOREIGN INTELLIGENCE SURVEILLANCE COURT OF REVIEW.

    (a) Technical Amendments.--The Foreign Intelligence Surveillance 
Act of 1978 (50 U.S.C. 1801 et seq.) is amended as follows:
            (1) In section 103(b) (50 U.S.C. 1803(b)), by striking 
        ``designate as the'' and inserting ``designated as the''.
            (2) In section 302(a)(1)(A)(iii) (50 U.S.C. 
        1822(a)(1)(A)(iii)), by striking ``paragraphs (1) through (4)'' 
        and inserting ``subparagraphs (A) through (D)''.
            (3) In section 406(b) (50 U.S.C. 1846(b)), by striking 
        ``and to the Committees on the Judiciary of the House of 
        Representatives and the Senate''.
            (4) In section 604(a) (50 U.S.C. 1874(a))--
                    (A) in paragraph (1)(D), by striking ``contents'' 
                and inserting ``contents,''; and
                    (B) in paragraph (3), by striking ``comply in the 
                into'' and inserting ``comply into''.
            (5) In section 701 (50 U.S.C. 1881)--
                    (A) in subsection (a), by striking ``The terms'' 
                and inserting ``In this title, the terms''; and
                    (B) in subsection (b)--
                            (i) by inserting ``In this title:'' after 
                        the subsection heading; and
                            (ii) in paragraph (5), by striking ``(50 
                        U.S.C. 401a(4))'' and inserting ``(50 U.S.C. 
                        3003(4))''.
            (6) In section 702(g)(2)(A)(i) (50 U.S.C. 
        1881a(g)(2)(A)(i)), by inserting ``targeting'' before 
        ``procedures in place''.
            (7) In section 801(7) (50 U.S.C. 1885(7)), by striking 
        ``(50 U.S.C. 401a(4))'' and inserting ``(50 U.S.C. 3003(4))''.
    (b) Court-Related Amendments.--The Foreign Intelligence 
Surveillance Act of 1978 (50 U.S.C. 1801 et seq.) is further amended as 
follows:
            (1) In section 103 (50 U.S.C. 1803)--
                    (A) in subsection (b), by striking ``immediately''; 
                and
                    (B) in subsection (h), by striking ``the court 
                established under subsection (a)'' and inserting ``a 
                court established under this section''.
            (2) In section 105(d) (50 U.S.C. 1805(d)), by adding at the 
        end the following new paragraph:
    ``(4) A denial of the application made under section 104 may be 
reviewed as provided in section 103.''.
            (3) In section 302(d) (50 U.S.C. 1822(d)), by striking 
        ``immediately''.
            (4) In section 402(d) (50 U.S.C. 1842(d)), by adding at the 
        end the following new paragraph:
    ``(3) A denial of the application made under this subsection may be 
reviewed as provided in section 103.''.
            (5) In section 403(c) (50 U.S.C. 1843(c)), by adding at the 
        end the following new paragraph:
    ``(3) A denial of the application made under subsection (a)(2) may 
be reviewed as provided in section 103.''.
            (6) In section 501(c) (50 U.S.C. 1861(c)), by adding at the 
        end the following new paragraph:
            ``(4) A denial of the application made under this 
        subsection may be reviewed as provided in section 103.''.

SEC. 308. SEVERABILITY.

    If any provision of this Act, any amendment made by this Act, or 
the application thereof to any person or circumstances is held invalid, 
the validity of the remainder of the Act, of any such amendments, and 
of the application of such provisions to other persons and 
circumstances shall not be affected thereby.

SEC. 309. RULE OF CONSTRUCTION.

    Nothing in this Act or the amendments made by this Act shall be 
construed to authorize the acquisition, querying, retention, 
dissemination, or use of information not previously authorized under 
the FISA Amendments Act of 2008 or the amendments made by that Act.
                                 <all>