Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors when Importing into Powershell #76

Closed
malhovic opened this issue Jan 22, 2016 · 2 comments
Closed

Errors when Importing into Powershell #76

malhovic opened this issue Jan 22, 2016 · 2 comments

Comments

@malhovic
Copy link

When running powershell (both with powershell -exec bypass or just setting the execution policy to unrestricted) I'm getting the below errors in trying to run Import-Module:

Import-Module : The module manifest 'C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1'
could not be processed because it is not a valid Windows PowerShell restricted language file. Remove the elements that
are not permitted by the restricted language:
At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:107 char:12

  •   <!-- </textarea> --><!-- '"` --><form accept-charset="UTF-8" action="/Powe ...
    
  •        ~
    
    The '<' operator is reserved for future use.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:840 char:203
  • ... hidden" value="✓" />
  •                ~
    
    The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
    quotation marks ("&") to pass it as part of a string.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:871 char:11
  •   <li>&copy; 2016 <span title="0.04437s from github-fe138-cp1-prd.iad.github ...
    
  •       ~
    
    The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
    quotation marks ("&") to pass it as part of a string.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:871 char:23
  •   <li>&copy; 2016 <span title="0.04437s from github-fe138-cp1-prd.iad.github ...
    
  •                   ~
    
    The '<' operator is reserved for future use.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:871 char:29
  •   <li>&copy; 2016 <span title="0.04437s from github-fe138-cp1-prd.iad.github ...
    
  •                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    Unexpected token 'title="0.04437s from github-fe138-cp1-prd.iad.github.net">GitHub' in expression or statement.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:871 char:100
  • ... ">GitHub, Inc.
  •                ~
    
    Missing argument in parameter list.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:904 char:83
  • ... tab or window. Reload to refresh your session.
  •                ~
    
    The '<' operator is reserved for future use.
    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PowerView\PowerView.psd1:905 char:83
  • ... tab or window. Reload to refresh your session.
  •                ~
    
    The '<' operator is reserved for future use.
    At line:1 char:1
  • Import-Module PowerView
  • - CategoryInfo          : ResourceUnavailable: (C:\Windows\syst...\PowerView.psd1:String) [Import-Module], Missing
      MemberException
    - FullyQualifiedErrorId : Modules_InvalidManifest,Microsoft.PowerShell.Commands.ImportModuleCommand
    
@void-in
Copy link

void-in commented Jan 29, 2016

I believe you have download the github html page and not the raw ps* files. You can download the zip archive and then extract it to a folder or if you want to download individual files then download the raw file such as https://raw.githubusercontent.com/PowerShellEmpire/PowerTools/master/PowerView/powerview.psd1

@mattifestation
Copy link

Yeah PowerShell won't execute HTML...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants